Project
View and manage all Project-wide settings, like countries, languages, and currencies, as well as feature-specific configurations via these endpoints.
Updating these settings is eventually consistent meaning that it can take up-to a minute until they become fully active for your Project.
Representations
Project
versionInt | Current version of the Project. |
keyString | User-defined unique identifier of the Project. |
nameString | Name of the Project. |
countriesArray of CountryCode | Country code of the geographic location. |
currenciesArray of CurrencyCode | Currency code of the country. A Project must have at least one currency. |
languagesArray of Locale | Language of the country. A Project must have at least one language. |
trialUntilString | Date in YYYY-MM format specifying when the trial period for the Project ends. Only present on Projects in trial period. |
messages | Holds the configuration for the Messages Query feature. |
carts | Holds the configuration for the Carts feature. |
shoppingLists | Holds the configuration for the Shopping Lists feature. This field may not be present on Projects created before January 2020. |
shippingRateInputType | Holds the configuration for the tiered shipping rates feature. |
externalOAuth | Represents a RFC 7662 compliant OAuth 2.0 Token Introspection endpoint. |
searchIndexing | Controls indexing of resources to be provided on high performance read-only search endpoints. |
businessUnitsBETA | Holds configuration specific to Business Units. |
createdAt | Date and time (UTC) the Project was initially created. |
MessagesConfiguration
Holds the configuration for the Messages Query feature for the Project.
enabledBoolean | When |
deleteDaysAfterCreationInt | Specifies the number of days each Message should be available via the Messages Query API. For Messages older than the specified period, it is not guaranteed that they are still accessible via the API. This field may not be present on Projects created before 8 October 2018. Default:15Minimum: 1Maximum: 90 |
MessagesConfigurationDraft
Defines the configuration for the Messages Query feature for the Project.
enabledBoolean | Setting to |
deleteDaysAfterCreationInt | Specifies the number of days each Message should be available via the Messages Query API. For Messages older than the specified period, it is not guaranteed that they are still accessible via the API. Minimum:1Maximum: 90 |
CartsConfiguration
deleteDaysAfterLastModificationInt | Default value for the 90Minimum: 1 |
countryTaxRateFallbackEnabledBoolean | Indicates if country - no state Tax Rate fallback should be used when a shipping address state is not explicitly covered in the rates lists of all Tax Categories of a Cart Line Items. This field may not be present on Projects created before June 2020. Default:false |
ShoppingListsConfiguration
deleteDaysAfterLastModificationInt | Default value for the 360 |
ShippingRateInputType
ShippingRatePriceTier can be dynamically selected in three ways. The CartValueType uses the sum of all Line Item Prices, whereas CartClassificationType and CartScoreType use the shipppingRateInput field on the Cart to select a tier.
CartValueType
CartClassificationType
Used when the ShippingRate maps to an abstract Cart categorization expressed by strings (for example, Light, Medium, or Heavy).
Only keys defined in the values array can be used to create a tier or to set a value of the shippingRateInput on the Cart.
Keys must be unique.
typeString | "CartClassification" |
valuesArray of CustomFieldLocalizedEnumValue | The classification items that can be used for specifying any ShippingRatePriceTier. |
{"type" : "CartClassification","values" : [ {"key" : "Light","label" : {"en" : "Light","de" : "Leicht"}}, {"key" : "Medium","label" : {"en" : "Medium","de" : "Mittel"}}, {"key" : "Heavy","label" : {"en" : "Heavy","de" : "Schwer"}} ]}
CartScoreType
Used when the ShippingRate maps to an abstract Cart categorization expressed by integers (such as shipping scores or weight ranges).
typeString | "CartScore" |
ExternalOAuth
Represents a RFC 7662 compliant OAuth 2.0 Token Introspection endpoint. For more information, see Requesting an access token using an external OAuth 2.0 server.
You can only configure one external OAuth 2.0 endpoint per Project. To authenticate using multiple external services (such as social network logins), use a middle layer authentication service.
urlString | URL with authorization header. |
authorizationHeaderString | Partially hidden on retrieval. |
SearchIndexingConfiguration
Controls indexing of resources to be provided on high performance read-only search endpoints.
products | Configuration for the Product Projection Search and Product Suggestions endpoints. |
ordersBETA | Configuration for the Order Search feature. |
SearchIndexingConfigurationValues
Current status of resource indexing. Present on Projects from 1 February 2019. | |
lastModifiedAt | Date and time (UTC) the Project was last updated. Only present on Projects last modified after 1 February 2019. |
lastModifiedByBETA | Present on resources created after 1 February 2019 except for events not tracked. |
SearchIndexingConfigurationStatus
Status of resource indexing.
ActivatedIndicates that search and suggest endpoints for the specified resource type are active.
DeactivatedIndicates that search and suggest endpoints for the specified resource type cannot be used.
IndexingIndicates that search and suggest endpoints can temporarily not be used because the search index is being re-built.
OrderSearchStatus BETA
Specifies the status of the Order Search index.
Activatedindicates that the Search Orders endpoint is fully operational.
Deactivatedindicates that the Order Search feature is currently not active, but can be activated by update action.
BusinessUnitConfiguration BETA
myBusinessUnitStatusOnCreation | Status of Business Units created using the My Business Unit endpoint. |
BusinessUnitConfigurationStatus BETA
Default value for Business Unit Status configured though Project settings.
ActiveThe Business Unit can be used in Orders, Carts, and Quotes and can be updated using the My Business Unit endpoint.
InactiveThe Business Unit cannot be used in Orders, Carts, and Quotes and cannot be updated using the My Business Unit endpoint.
Get Project
view_project_settings:{projectKey}regionString | Region in which the Project is hosted. |
projectKeyString |
|
200Project
curl -X GET https://api.{region}.commercetools.com/{projectKey} -i \--header 'Authorization: Bearer ${BEARER_TOKEN}'
{"version" : 1,"key" : "test-project","name" : "Some project name","countries" : [ "DE", "US" ],"currencies" : [ "EUR" ],"languages" : [ "en" ],"createdAt" : "2013-11-01T15:14:34.325Z","trialUntil" : "2013-11-01T15:14:34.325Z","messages" : {"enabled" : false},"carts" : {"countryTaxRateFallbackEnabled" : false}}
Update Project
manage_project:{projectKey}regionString | Region in which the Project is hosted. |
projectKeyString |
|
versionInt | Expected version of the Project on which the changes should be applied. If the expected version does not match the actual version, a 409 Conflict will be returned. |
actionsArray of ProjectUpdateAction | Update actions to be performed on the Project. |
200Project
{"version" : 1,"key" : "test-project","name" : "Some project name","countries" : [ "DE", "US" ],"currencies" : [ "EUR" ],"languages" : [ "en" ],"createdAt" : "2013-11-01T15:14:34.325Z","trialUntil" : "2013-11-01T15:14:34.325Z","messages" : {"enabled" : false},"carts" : {"countryTaxRateFallbackEnabled" : false}}
Update actions
Change Name
actionString | "changeName" |
nameString | New value to set. Must not be empty. |
{"action" : "changeName","name" : "CTP Postman Monitor"}
Change Currencies
actionString | "changeCurrencies" |
currenciesArray of CurrencyCode | New value to set. Must not be empty. |
{"action" : "changeCurrencies","currencies" : [ "EUR" ]}
Change Countries
actionString | "changeCountries" |
countriesArray of CountryCode | New value to set. Must not be empty. |
{"action" : "changeCountries","countries" : [ "DE", "US" ]}
Change Languages
If a language is used by a Store, it cannot be deleted. Attempts to delete such language will lead to LanguageUsedInStores errors.
actionString | "changeLanguages" |
languagesArray of Locale | New value to set. Must not be empty. |
{"action" : "changeLanguages","languages" : [ "en", "de", "de-DE" ]}
Change Messages Configuration
actionString | "changeMessagesConfiguration" |
messagesConfiguration | Configuration for the Messages Query feature. |
{"action" : "changeMessagesConfiguration","messagesConfiguration" : {"enabled" : true,"deleteDaysAfterCreation" : 30}}
Change Carts Configuration
actionString | "changeCartsConfiguration" |
cartsConfiguration | Configuration for the Carts feature. |
Change CountryTaxRateFallbackEnabled
actionString | "changeCountryTaxRateFallbackEnabled" |
countryTaxRateFallbackEnabledBoolean | When false |
{"action" : "changeCountryTaxRateFallbackEnabled","countryTaxRateFallbackEnabled" : true}
Change ShoppingLists Configuration
actionString | "changeShoppingListsConfiguration" |
shoppingListsConfiguration | Configuration for the Shopping Lists feature. |
Change My Business Unit Status on Creation BETA
actionString | "changeMyBusinessUnitStatusOnCreation" |
status | Status for Business Units created using the My Business Unit endpoint. |
{"action" : "changeMyBusinessUnitStatusOnCreation","status" : "Active"}
Set ShippingRateInputType
actionString | "setShippingRateInputType" |
shippingRateInputType | Value to set. If empty, any existing value will be removed. |
{"action" : "setShippingRateInputType","shippingRateInputType" : {"type" : "CartScore"}}
Set ExternalOAuth
actionString | "setExternalOAuth" |
externalOAuth | Value to set. If empty, any existing value will be removed. |
Change Product Search Indexing Enabled
actionString | "changeProductSearchIndexingEnabled" |
enabledBoolean | If If |
{"action" : "changeProductSearchIndexingEnabled","enabled" : true}
Change Order Search Status BETA
actionString | "changeOrderSearchStatus" |
status | Activates or deactivates the Order Search feature. Activation will trigger building a search index for the Orders in the Project. |
{"action" : "changeOrderSearchStatus","status" : "Activated"}