# Models

## The AddressDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"AddressDto":{"title":"Address","type":"object","required":["country","zipCode"],"properties":{"street":{"type":"string"},"streetNumber":{"type":"string"},"streetAppendix":{"type":"string"},"extraLine1":{"type":"string"},"extraLine2":{"type":"string"},"extraLine3":{"type":"string"},"extraLine4":{"type":"string"},"zipCode":{"type":"string"},"city":{"type":"string"},"country":{"type":"string"},"state":{"type":"string"}},"description":"Site address."}}}}
```

## The CurrencyDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"CurrencyDto":{"type":"string","description":"Currency used by the site, compliant with the ISO 4217 standard.","minLength":3,"maxLength":3,"pattern":"^[A-Z]{3}"}}}}
```

## The DefaultDtoMetadata object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"DefaultDtoMetadata":{"title":"Metadata","type":"object","properties":{"mixins":{"type":"object","description":"Mixin schema URLs.","additionalProperties":true},"version":{"type":"integer"}}}}}}
```

## The HomeBaseDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"HomeBaseDto":{"title":"HomeBase","type":"object","required":["address"],"properties":{"address":{"$ref":"#/components/schemas/AddressDto"},"location":{"$ref":"#/components/schemas/LocationDto"},"timezone":{"type":"string","description":"The timezone of the site home base location. Must be a valid IANA timezone identifier.\n\nIf not specified, no timezone will be set. When specified, the value must be a valid timezone ID as defined in the IANA Time Zone Database.\n\nExamples of valid timezones:\n- Europe/Paris\n- America/New_York \n- Asia/Tokyo\n- UTC\n\nInvalid timezone values (e.g., \"Europe/Xp\") will result in a 400 Bad Request response.\n"}},"description":"Site location."},"AddressDto":{"title":"Address","type":"object","required":["country","zipCode"],"properties":{"street":{"type":"string"},"streetNumber":{"type":"string"},"streetAppendix":{"type":"string"},"extraLine1":{"type":"string"},"extraLine2":{"type":"string"},"extraLine3":{"type":"string"},"extraLine4":{"type":"string"},"zipCode":{"type":"string"},"city":{"type":"string"},"country":{"type":"string"},"state":{"type":"string"}},"description":"Site address."},"LocationDto":{"title":"Location","type":"object","properties":{"latitude":{"type":"number","format":"double"},"longitude":{"type":"number","format":"double"}},"description":"Site geographical location."}}}}
```

## The LocationDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"LocationDto":{"title":"Location","type":"object","properties":{"latitude":{"type":"number","format":"double"},"longitude":{"type":"number","format":"double"}},"description":"Site geographical location."}}}}
```

## The SiteDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"SiteDto":{"title":"Site","type":"object","description":"Information about the site.","required":["code","name","defaultLanguage","languages","currency","homeBase","shipToCountries","taxDeterminationBasedOn"],"properties":{"code":{"type":"string","pattern":"^[^\\s#]+$","description":"Site unique identifier."},"name":{"type":"string","description":"Site name."},"active":{"type":"boolean","description":"Flag indicating whether the site is active."},"default":{"type":"boolean","description":"Flag indicating whether the site is the  tenant default site."},"includesTax":{"type":"boolean","description":"Indicates whether prices for the site should be returned in gross (when includesTax=true) or net (when includesTax=false). "},"defaultLanguage":{"type":"string","description":"Site's default language, compliant with the ISO 639-1 standard.","minLength":2,"maxLength":2,"pattern":"^[a-z]{2}"},"languages":{"type":"array","description":"Languages supported by the site.\n\n**Note**: The languages must be compliant with the ISO 639-1 standard.","items":{"type":"string","minLength":2,"maxLength":2,"pattern":"^[a-z]{2}"}},"currency":{"$ref":"#/components/schemas/CurrencyDto"},"availableCurrencies":{"type":"array","description":"List of the currencies supported by the site","items":{"$ref":"#/components/schemas/CurrencyDto"}},"homeBase":{"$ref":"#/components/schemas/HomeBaseDto"},"shipToCountries":{"type":"array","description":"Codes of countries to which the site ships products.\n\n**Note**: The country codes must be compliant with the ISO 3166-1 alpha-2 standard.","items":{"type":"string","minLength":2,"maxLength":2,"pattern":"^[A-Z]{2}"}},"shipping":{"type":"array","description":"Shipping service configurations.","items":{"$ref":"#/components/schemas/ServiceConfigurationDto"}},"payment":{"type":"array","description":"Payment service configurations.","items":{"$ref":"#/components/schemas/ServiceConfigurationDto"}},"tax":{"type":"array","description":"`Preview feature - the feature is not fully operated yet.` \nTax service configurations.","items":{"$ref":"#/components/schemas/ServiceConfigurationDto"}},"assistedBuying":{"$ref":"#/components/schemas/AssistedBuying"},"metadata":{"$ref":"#/components/schemas/DefaultDtoMetadata"},"taxDeterminationBasedOn":{"$ref":"#/components/schemas/taxDeterminationBasedOn"},"mixins":{"type":"object","description":"Site additional properties.","additionalProperties":true},"cartCalculationScale":{"type":"integer","description":"Number of decimal points used in the cart calculation. Must be zero or a positive value.","default":2,"minimum":0}}},"CurrencyDto":{"type":"string","description":"Currency used by the site, compliant with the ISO 4217 standard.","minLength":3,"maxLength":3,"pattern":"^[A-Z]{3}"},"HomeBaseDto":{"title":"HomeBase","type":"object","required":["address"],"properties":{"address":{"$ref":"#/components/schemas/AddressDto"},"location":{"$ref":"#/components/schemas/LocationDto"},"timezone":{"type":"string","description":"The timezone of the site home base location. Must be a valid IANA timezone identifier.\n\nIf not specified, no timezone will be set. When specified, the value must be a valid timezone ID as defined in the IANA Time Zone Database.\n\nExamples of valid timezones:\n- Europe/Paris\n- America/New_York \n- Asia/Tokyo\n- UTC\n\nInvalid timezone values (e.g., \"Europe/Xp\") will result in a 400 Bad Request response.\n"}},"description":"Site location."},"AddressDto":{"title":"Address","type":"object","required":["country","zipCode"],"properties":{"street":{"type":"string"},"streetNumber":{"type":"string"},"streetAppendix":{"type":"string"},"extraLine1":{"type":"string"},"extraLine2":{"type":"string"},"extraLine3":{"type":"string"},"extraLine4":{"type":"string"},"zipCode":{"type":"string"},"city":{"type":"string"},"country":{"type":"string"},"state":{"type":"string"}},"description":"Site address."},"LocationDto":{"title":"Location","type":"object","properties":{"latitude":{"type":"number","format":"double"},"longitude":{"type":"number","format":"double"}},"description":"Site geographical location."},"ServiceConfigurationDto":{"title":"Service Configuration","type":"object","properties":{"id":{"type":"string","description":"Service configuration's unique identifier."},"name":{"type":"string","description":"Service configuration's name."},"serviceType":{"type":"string"},"serviceUrl":{"type":"string"},"active":{"type":"boolean","default":true,"description":"Flag indicating whether the service is active."},"configuration":{"$ref":"#/components/schemas/ServiceSettingsDto"}}},"ServiceSettingsDto":{"title":"Service Settings","type":"object","properties":{"public":{"type":"object"},"restricted":{"type":"object"}}},"AssistedBuying":{"title":"AssistedBuying","type":"object","properties":{"storefrontUrl":{"type":"string","description":"Storefront URL, where an employee should be redirected when the assisted buying mechanism is used."}}},"DefaultDtoMetadata":{"title":"Metadata","type":"object","properties":{"mixins":{"type":"object","description":"Mixin schema URLs.","additionalProperties":true},"version":{"type":"integer"}}},"taxDeterminationBasedOn":{"type":"string","enum":["BILLING_ADDRESS","SHIPPING_ADDRESS"],"description":"Specifies whether tax calculation is based on customer billing address or shipping address. Default value is `BILLING_ADDRESS`."}}}}
```

## The ServiceConfigurationDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"ServiceConfigurationDto":{"title":"Service Configuration","type":"object","properties":{"id":{"type":"string","description":"Service configuration's unique identifier."},"name":{"type":"string","description":"Service configuration's name."},"serviceType":{"type":"string"},"serviceUrl":{"type":"string"},"active":{"type":"boolean","default":true,"description":"Flag indicating whether the service is active."},"configuration":{"$ref":"#/components/schemas/ServiceSettingsDto"}}},"ServiceSettingsDto":{"title":"Service Settings","type":"object","properties":{"public":{"type":"object"},"restricted":{"type":"object"}}}}}}
```

## The ServiceSettingsDto object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"ServiceSettingsDto":{"title":"Service Settings","type":"object","properties":{"public":{"type":"object"},"restricted":{"type":"object"}}}}}}
```

## The ResourceLocation object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"ResourceLocation":{"title":"ResourceLocation","type":"object","properties":{"id":{"type":"string","description":"Resource identifier."}},"description":""}}}}
```

## The ErrorMessage object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"ErrorMessage":{"type":"object","properties":{"type":{"type":"string","description":"Classification of the error type.\n\n**Note**: The error type should be written in lowercase and include underscores, for example validation_failure."},"status":{"type":"number","minimum":100,"maximum":599,"description":"Original HTTP error code. It should be consistent with the HTTP response code."},"message":{"type":"string","description":"Descriptive error message for debugging purposes."},"details":{"type":"array","items":{"type":"object","properties":{"message":{"type":"string"}}}}}}}}}
```

## The Mixin object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"Mixin":{"title":"Mixin","type":"object","description":"Represents a single mixin. The payload is represented as a map with a single key and value, where key represents a mixin group name and value represents a map with keys and values.","additionalProperties":true}}}}
```

## The Mixins object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"Mixins":{"title":"Mixins","type":"object","description":"Represents mixins. The object is represented as a map with keys and values, where key represents a mixin group name and value represents a map with keys and values.","additionalProperties":true}}}}
```

## The AssistedBuying object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"AssistedBuying":{"title":"AssistedBuying","type":"object","properties":{"storefrontUrl":{"type":"string","description":"Storefront URL, where an employee should be redirected when the assisted buying mechanism is used."}}}}}}
```

## The taxDeterminationBasedOn object

```json
{"openapi":"3.0.0","info":{"title":"Site Settings Service","version":"0.0.1"},"components":{"schemas":{"taxDeterminationBasedOn":{"type":"string","enum":["BILLING_ADDRESS","SHIPPING_ADDRESS"],"description":"Specifies whether tax calculation is based on customer billing address or shipping address. Default value is `BILLING_ADDRESS`."}}}}
```
