Skip to content

AddCustomerAddress

// RB2 Core Connect
using HotChocolate;
namespace CoreConnect.Commerce.Customer;
/// <summary>
/// Represents a request to add a customer's address.
/// </summary>
public record AddCustomerAddressRequest
{
/// <summary>
/// Initializes a new instance of the <see cref="AddCustomerAddressRequest"/> class.
/// </summary>
/// <param name="isDefault"></param>
/// /// <param name="type"></param>
/// <param name="firstName"></param>
/// <param name="lastName"></param>
/// <param name="address1"></param>
/// <param name="houseNumber"></param>
/// <param name="salutation"></param>
/// <param name="postalCode"></param>
/// <param name="city"></param>
/// <param name="countryCode"></param>
/// <param name="isDefaultBilling"></param>
/// <param name="isDefaultShipping"></param>
public AddCustomerAddressRequest(
bool isDefault,
AddressType? type,
string firstName,
string lastName,
string address1,
string houseNumber,
string? salutation,
string postalCode,
string city,
string countryCode,
bool isDefaultBilling,
bool isDefaultShipping)
{
IsDefault = isDefault;
Type = type;
FirstName = firstName;
LastName = lastName;
Address1 = address1;
HouseNumber = houseNumber;
Salutation = salutation;
PostalCode = postalCode;
City = city;
CountryCode = countryCode;
IsDefaultBilling = isDefaultBilling;
IsDefaultShipping = isDefaultShipping;
}
[GraphQLIgnore]
public string? CustomerId { get; set; }
public bool IsDefault { get; set; }
public bool IsDefaultBilling { get; set; }
public bool IsDefaultShipping { get; set; }
public AddressType[]? IsDefaultForTypes { get; set; }
public AddressType? Type { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string? Company { get; set; }
public string Address1 { get; set; }
public string? Address2 { get; set; }
public string? HouseNumber { get; set; }
public string? Salutation { get; set; }
public string PostalCode { get; set; }
public string City { get; set; }
public string? StateOrProvince { get; set; }
public string CountryCode { get; set; }
public string? Phone { get; set; }
public string? StreetNumber { get; set; }
public string? AdditionalStreetInfo { get; set; }
}