-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release v2.0.0 - @W-15675100@ (#153)
* add updated APIs * revert shopper basket changes * update docs * Update for v1.14.0 * update changelog * update docs * remove authorizeCustomer from unit tests * bump major version
- Loading branch information
1 parent
d336d21
commit 7783054
Showing
430 changed files
with
8,758 additions
and
2,559 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,25 @@ | ||
{ | ||
"main": "shopper-context.raml", | ||
"name": "Shopper Context", | ||
"classifier": "raml", | ||
"tags": [], | ||
"dependencies": [ | ||
{ | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"version": "1.1.15", | ||
"assetId": "api-standards", | ||
"version": "1.1.15" | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
}, | ||
{ | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"version": "2.0.0", | ||
"assetId": "commerce-cloud-standards", | ||
"version": "1.0.24" | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
} | ||
], | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"assetId": "shopper-context", | ||
"version": "0.0.23", | ||
"apiVersion": "v1", | ||
"version": "0.0.26", | ||
"originalFormatVersion": "1.0", | ||
"organizationId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
"apiVersion": "v1", | ||
"descriptorVersion": "0.1.0", | ||
"classifier": "raml", | ||
"main": "shopper-context.raml", | ||
"assetId": "shopper-context", | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"organizationId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"name": "Shopper Context", | ||
"tags": [] | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
118 changes: 118 additions & 0 deletions
118
...-10e2-423a-bdb4-f952f56eb6d8/commerce-cloud-standards/2.0.0/commerce-cloud-standards.raml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
#%RAML 1.0 Library | ||
usage: |- | ||
The Commerce Cloud API Standards is a collection of types, traits, security schemes, and more that follows the standards that are defined for the B2C Commerce APIs. Use this standard library in conjunction with the Salesforce API Standards library, via the `uses` property. See the main RAML file for any of the B2C Commerce APIs for example usage. | ||
The goal of this library is to expose only the importable objects and keep other, internal details as private. If you have suggestions for adding to the standard, contact the C4E team with your proposal. | ||
# Security Schemes | ||
This library provides the following reusable security schemes. Except in rare circumstances, avoid defining a custom security scheme for a single API. The security schemes provided here or in the Salesforce API Standards are designed to meet the needs of most applications. | ||
Security schemes included in Commerce Cloud Standards: | ||
- `AmOAuth2`: for endpoints authenticated against [Account Manager](https://account.demandware.com/dw/account/Home#/) OAuth 2.0. | ||
- `ShopperToken`: for endpoints authenticated via Shopper JWTs. | ||
## Types | ||
This library provides the following reusable types. These types are referenced in a plurality of APIs, to the point where it makes sense to have a common definition where the documentation, validation, and usage of them can be well documented. | ||
- `SiteId`: a type that describes the storefront context for requests by a Shopper. If you need to have a siteId queryParam, use the trait `SiteSpecific`. | ||
## Search Specific | ||
- `SearchRequest`: a type commonly used for searching that takes a query in a body. | ||
- `PaginatedSearchResult`: a type commonly used for a search response that took a query in a body. | ||
- `SimpleSearchResult`: a type used for a search response that takes a query in a body, but does not return a paginated result. | ||
## Standards Followed | ||
- `CurrencyCode`: ISO 4217 compliant currency code. | ||
- `Money`: A combination of a CurrencyCode and a number. | ||
- `LanguageCode`: ISO 639-1 compliant language code. | ||
- `CountryCode`: ISO 3166-1 compliant country code. | ||
- `LocaleCode`: A combination of LanguageCode and CountryCode. | ||
## Resource Types | ||
This project provides the following reusable resource types. These resource types are referenced in a plurality of APIs, to the point where it makes sense to have a common definition where the documentation, validation, and usage of them can be well documented. | ||
- `Organization`: a type that describes the `organizationId` URI parameter that the majority of Commerce Cloud APIs require in the resource path after the `version`. The beginning of all API resource paths is expected to be `/organizations/{organizationId}`. This resource type provides the documentation and validation of the `organizationId`. | ||
## Traits | ||
This project provides the following reusable traits. These traits are referenced in a plurality of APIs, to the point where it makes sense to have a common definition where the documentation, validation, and usage of them can be well documented. | ||
- `Selectable`: adds a query parameter called `select` of type `Select` to the request. | ||
- `SiteSpecific`: adds a query parameter called `siteId` of type `SiteId` to the request. | ||
- `QueryParamsLimit`: adds an offset query parameter without the limit query parameter. Some Commerce Cloud use cases do not currently require both. Prefer the use of `ApiStandards.OffsetPaginated` because this trait will be deprecated in the future if there is no use case for it. | ||
- `QueryParamsOffset`: adds a limit query parameter without the offset query parameter. Some Commerce Cloud use cases do not currently require both. Prefer the use of `ApiStandards.OffsetPaginated` because this trait will be deprecated in the future if there is no use case for it. | ||
uses: | ||
AdditionalProperties: Types/additional-properties.raml | ||
Search: Types/search-types.raml | ||
Pagination: Types/pagination-types.raml | ||
ISO: Types/ISO-standards.raml | ||
AttributeDefinitions: Types/attribute-definition-types.raml | ||
|
||
securitySchemes: | ||
AmOAuth2: !include SecuritySchemes/am-oauth-2.raml | ||
ShopperToken: !include SecuritySchemes/shopper-token.raml | ||
ShopperTokenTsob: !include SecuritySchemes/shopper-token-tsob.raml | ||
ShopperTokenTaob: !include SecuritySchemes/shopper-token-taob.raml | ||
|
||
types: | ||
SiteId: | ||
description: The identifer of the site that a request is being made in the context of. Attributes might have site specific values, and some objects may only be assigned to specific sites | ||
example: | ||
SiteGenesis | ||
type: string | ||
minLength: 1 | ||
Select: | ||
description: The property selector declaring which fields are included into the response payload. You can specify a single field name, a comma-separated list of names or work with wildcards. You can also specify array operations and filter expressions. The actual selector value must be enclosed within parentheses. | ||
example: | ||
(name,id,variationAttributes.(**)) | ||
type: string | ||
minLength: 1 | ||
SearchRequest: Search.SearchRequestBase | ||
PaginatedSearchResult: Search.PaginatedSearchResultBase | ||
SimpleSearchResult: Search.SimpleSearchResultBase | ||
|
||
CurrencyCode: ISO.Currency | ||
Money: ISO.MoneyMnemonic | ||
LanguageCode: ISO.Language | ||
CountryCode: ISO.Country | ||
LocaleCode: ISO.Locale | ||
LocalizedString: ISO.L10nString | ||
|
||
PropertyDefinition: AttributeDefinitions.AttributeDefinition | ||
|
||
ClosedObject: AdditionalProperties.NoPropertiesAllowed | ||
OpenObject: AdditionalProperties.SpecifiedPropertiesAllowed | ||
|
||
resourceTypes: | ||
Organization: | ||
uriParameters: | ||
organizationId: | ||
description: An identifier for the organization the request is being made by. | ||
example: | ||
f_ecom_zzxy_prd | ||
|
||
traits: | ||
QueryParamsLimit: | ||
usage: This trait should not be used unless there is no requirement for QueryParamsOffset. Prefer the usage of ApiStandards.OffsetPaginated. | ||
queryParameters: | ||
limit?: Pagination.Limit | ||
QueryParamsOffset: | ||
usage: This trait should not be used unless there is no requirement for QueryParamsLimit. Prefer the usage of ApiStandards.OffsetPaginated. | ||
queryParameters: | ||
offset?: Pagination.Offset | ||
SiteSpecific: | ||
usage: This trait should be used whenever a resource has the context of a site assoicated with its request. This will add a siteId query parameter | ||
queryParameters: | ||
siteId: SiteId | ||
Selectable: | ||
usage: This trait should be used whenever a resource supports generic property selection. This will add a select query parameter. | ||
queryParameters: | ||
select?: Select |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
...modules/893f605e-10e2-423a-bdb4-f952f56eb6d8/commerce-cloud-standards/2.0.0/exchange.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"main": "commerce-cloud-standards.raml", | ||
"name": "Commerce Cloud Standards", | ||
"classifier": "raml-fragment", | ||
"tags": [], | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"assetId": "commerce-cloud-standards", | ||
"version": "2.0.0", | ||
"organizationId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,25 @@ | ||
{"main":"shopper-customers.raml","name":"Shopper Customers","classifier":"raml","tags":[],"dependencies":[{"groupId":"893f605e-10e2-423a-bdb4-f952f56eb6d8","assetId":"api-standards","version":"1.1.15"},{"groupId":"893f605e-10e2-423a-bdb4-f952f56eb6d8","assetId":"commerce-cloud-standards","version":"1.0.24"}],"groupId":"893f605e-10e2-423a-bdb4-f952f56eb6d8","assetId":"shopper-customers","version":"0.0.43","apiVersion":"v1","originalFormatVersion":"1.0","organizationId":"893f605e-10e2-423a-bdb4-f952f56eb6d8"} | ||
{ | ||
"dependencies": [ | ||
{ | ||
"version": "1.1.15", | ||
"assetId": "api-standards", | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
}, | ||
{ | ||
"version": "2.0.0", | ||
"assetId": "commerce-cloud-standards", | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8" | ||
} | ||
], | ||
"version": "0.0.48", | ||
"originalFormatVersion": "1.0", | ||
"apiVersion": "v1", | ||
"descriptorVersion": "0.1.0", | ||
"classifier": "raml", | ||
"main": "shopper-customers.raml", | ||
"assetId": "shopper-customers", | ||
"groupId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"organizationId": "893f605e-10e2-423a-bdb4-f952f56eb6d8", | ||
"name": "Shopper Customers", | ||
"tags": [] | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.