{ "openapi": "3.0.1", "info": { "title": "Commerce Layer Provisioning API", "version": "1.0.15", "contact": { "name": "API Support", "url": "https://commercelayer.io", "email": "support@commercelayer.io" }, "description": "Headless Commerce for Global Brands." }, "servers": [ { "url": "https://provisioning.commercelayer.io", "description": "Commerce Layer Provisioning API" }, { "url": "https://docs.commercelayer.io/provisioning-api", "description": "API reference" } ], "paths": { "/api_credentials": { "post": { "operationId": "POST/api_credentials", "summary": "Creates an API credential", "description": "Creates an API credential", "tags": [ "api_credentials" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialCreate" } } } }, "responses": { "201": { "description": "The created API credential object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialResponse" } } } } } }, "get": { "operationId": "GET/api_credentials", "summary": "List all API credentials", "description": "List all API credentials", "tags": [ "api_credentials" ], "responses": { "200": { "description": "A list of API credential objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialResponseList" } } } } } } }, "/api_credentials/{apiCredentialId}": { "get": { "operationId": "GET/api_credentials/apiCredentialId", "summary": "Retrieve an API credential", "description": "Retrieve an API credential", "parameters": [ { "name": "apiCredentialId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "api_credentials" ], "responses": { "200": { "description": "The API credential object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialResponse" } } } } } }, "patch": { "operationId": "PATCH/api_credentials/apiCredentialId", "summary": "Updates an API credential", "description": "Updates an API credential", "tags": [ "api_credentials" ], "parameters": [ { "name": "apiCredentialId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialUpdate" } } } }, "responses": { "200": { "description": "The updated API credential object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/apiCredentialResponse" } } } } } }, "delete": { "operationId": "DELETE/api_credentials/apiCredentialId", "summary": "Delete an API credential", "description": "Delete an API credential", "tags": [ "api_credentials" ], "parameters": [ { "name": "apiCredentialId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "204": { "description": "No content" } } } }, "/api_credentials/{apiCredentialId}/organization": { "get": { "operationId": "GET/apiCredentialId/organization", "summary": "Related API credential", "description": "Related API credential", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "apiCredentialId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the API credential" } } } }, "/api_credentials/{apiCredentialId}/role": { "get": { "operationId": "GET/apiCredentialId/role", "summary": "Related API credential", "description": "Related API credential", "tags": [ "roles", "has_one" ], "parameters": [ { "name": "apiCredentialId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The role associated to the API credential" } } } }, "/application_memberships": { "post": { "operationId": "POST/application_memberships", "summary": "Creates an application membership", "description": "Creates an application membership", "tags": [ "application_memberships" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipCreate" } } } }, "responses": { "201": { "description": "The created application membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipResponse" } } } } } }, "get": { "operationId": "GET/application_memberships", "summary": "List all application memberships", "description": "List all application memberships", "tags": [ "application_memberships" ], "responses": { "200": { "description": "A list of application membership objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipResponseList" } } } } } } }, "/application_memberships/{applicationMembershipId}": { "get": { "operationId": "GET/application_memberships/applicationMembershipId", "summary": "Retrieve an application membership", "description": "Retrieve an application membership", "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "application_memberships" ], "responses": { "200": { "description": "The application membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipResponse" } } } } } }, "patch": { "operationId": "PATCH/application_memberships/applicationMembershipId", "summary": "Updates an application membership", "description": "Updates an application membership", "tags": [ "application_memberships" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipUpdate" } } } }, "responses": { "200": { "description": "The updated application membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/applicationMembershipResponse" } } } } } }, "delete": { "operationId": "DELETE/application_memberships/applicationMembershipId", "summary": "Delete an application membership", "description": "Delete an application membership", "tags": [ "application_memberships" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "204": { "description": "No content" } } } }, "/application_memberships/{applicationMembershipId}/api_credential": { "get": { "operationId": "GET/applicationMembershipId/api_credential", "summary": "Related application membership", "description": "Related application membership", "tags": [ "api_credentials", "has_one" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The api_credential associated to the application membership" } } } }, "/application_memberships/{applicationMembershipId}/membership": { "get": { "operationId": "GET/applicationMembershipId/membership", "summary": "Related application membership", "description": "Related application membership", "tags": [ "memberships", "has_one" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The membership associated to the application membership" } } } }, "/application_memberships/{applicationMembershipId}/membership_profile": { "get": { "operationId": "GET/applicationMembershipId/membership_profile", "summary": "Related application membership", "description": "Related application membership", "tags": [ "membership_profiles", "has_one" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The membership_profile associated to the application membership" } } } }, "/application_memberships/{applicationMembershipId}/organization": { "get": { "operationId": "GET/applicationMembershipId/organization", "summary": "Related application membership", "description": "Related application membership", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the application membership" } } } }, "/application_memberships/{applicationMembershipId}/role": { "get": { "operationId": "GET/applicationMembershipId/role", "summary": "Related application membership", "description": "Related application membership", "tags": [ "roles", "has_one" ], "parameters": [ { "name": "applicationMembershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The role associated to the application membership" } } } }, "/identity_providers": { "post": { "operationId": "POST/identity_providers", "summary": "Creates an identity provider", "description": "Creates an identity provider", "tags": [ "identity_providers" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderCreate" } } } }, "responses": { "201": { "description": "The created identity provider object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderResponse" } } } } } }, "get": { "operationId": "GET/identity_providers", "summary": "List all identity providers", "description": "List all identity providers", "tags": [ "identity_providers" ], "responses": { "200": { "description": "A list of identity provider objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderResponseList" } } } } } } }, "/identity_providers/{identityProviderId}": { "get": { "operationId": "GET/identity_providers/identityProviderId", "summary": "Retrieve an identity provider", "description": "Retrieve an identity provider", "parameters": [ { "name": "identityProviderId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "identity_providers" ], "responses": { "200": { "description": "The identity provider object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderResponse" } } } } } }, "patch": { "operationId": "PATCH/identity_providers/identityProviderId", "summary": "Updates an identity provider", "description": "Updates an identity provider", "tags": [ "identity_providers" ], "parameters": [ { "name": "identityProviderId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderUpdate" } } } }, "responses": { "200": { "description": "The updated identity provider object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/identityProviderResponse" } } } } } }, "delete": { "operationId": "DELETE/identity_providers/identityProviderId", "summary": "Delete an identity provider", "description": "Delete an identity provider", "tags": [ "identity_providers" ], "parameters": [ { "name": "identityProviderId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "204": { "description": "No content" } } } }, "/identity_providers/{identityProviderId}/user": { "get": { "operationId": "GET/identityProviderId/user", "summary": "Related identity provider", "description": "Related identity provider", "tags": [ "users", "has_one" ], "parameters": [ { "name": "identityProviderId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The user associated to the identity provider" } } } }, "/memberships": { "post": { "operationId": "POST/memberships", "summary": "Creates an membership", "description": "Creates an membership", "tags": [ "memberships" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipCreate" } } } }, "responses": { "201": { "description": "The created membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipResponse" } } } } } }, "get": { "operationId": "GET/memberships", "summary": "List all memberships", "description": "List all memberships", "tags": [ "memberships" ], "responses": { "200": { "description": "A list of membership objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipResponseList" } } } } } } }, "/memberships/{membershipId}": { "get": { "operationId": "GET/memberships/membershipId", "summary": "Retrieve an membership", "description": "Retrieve an membership", "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "memberships" ], "responses": { "200": { "description": "The membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipResponse" } } } } } }, "patch": { "operationId": "PATCH/memberships/membershipId", "summary": "Updates an membership", "description": "Updates an membership", "tags": [ "memberships" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipUpdate" } } } }, "responses": { "200": { "description": "The updated membership object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipResponse" } } } } } }, "delete": { "operationId": "DELETE/memberships/membershipId", "summary": "Delete an membership", "description": "Delete an membership", "tags": [ "memberships" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "204": { "description": "No content" } } } }, "/memberships/{membershipId}/resend": { "post": { "operationId": "POST/memberships/membershipId/resend", "summary": "Resend invitation", "description": "Resend invitation for the given membership", "tags": [ "memberships" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": {} } }, "responses": { "202": { "description": "Confirmation that the invitation has been sent", "content": {} } } } }, "/memberships/{membershipId}/organization": { "get": { "operationId": "GET/membershipId/organization", "summary": "Related membership", "description": "Related membership", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the membership" } } } }, "/memberships/{membershipId}/role": { "get": { "operationId": "GET/membershipId/role", "summary": "Related membership", "description": "Related membership", "tags": [ "roles", "has_one" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The role associated to the membership" } } } }, "/memberships/{membershipId}/application_memberships": { "get": { "operationId": "GET/membershipId/application_memberships", "summary": "Related membership", "description": "Related membership", "tags": [ "application_memberships", "has_many" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The application_memberships associated to the membership" } } } }, "/memberships/{membershipId}/membership_profile": { "get": { "operationId": "GET/membershipId/membership_profile", "summary": "Related membership", "description": "Related membership", "tags": [ "membership_profiles", "has_one" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The membership_profile associated to the membership" } } } }, "/memberships/{membershipId}/versions": { "get": { "operationId": "GET/membershipId/versions", "summary": "Related membership", "description": "Related membership", "tags": [ "versions", "has_many" ], "parameters": [ { "name": "membershipId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The versions associated to the membership" } } } }, "/membership_profiles": { "post": { "operationId": "POST/membership_profiles", "summary": "Creates an membership profile", "description": "Creates an membership profile", "tags": [ "membership_profiles" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileCreate" } } } }, "responses": { "201": { "description": "The created membership profile object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileResponse" } } } } } }, "get": { "operationId": "GET/membership_profiles", "summary": "List all membership profiles", "description": "List all membership profiles", "tags": [ "membership_profiles" ], "responses": { "200": { "description": "A list of membership profile objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileResponseList" } } } } } } }, "/membership_profiles/{membershipProfileId}": { "get": { "operationId": "GET/membership_profiles/membershipProfileId", "summary": "Retrieve an membership profile", "description": "Retrieve an membership profile", "parameters": [ { "name": "membershipProfileId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "membership_profiles" ], "responses": { "200": { "description": "The membership profile object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileResponse" } } } } } }, "patch": { "operationId": "PATCH/membership_profiles/membershipProfileId", "summary": "Updates an membership profile", "description": "Updates an membership profile", "tags": [ "membership_profiles" ], "parameters": [ { "name": "membershipProfileId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileUpdate" } } } }, "responses": { "200": { "description": "The updated membership profile object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/membershipProfileResponse" } } } } } }, "delete": { "operationId": "DELETE/membership_profiles/membershipProfileId", "summary": "Delete an membership profile", "description": "Delete an membership profile", "tags": [ "membership_profiles" ], "parameters": [ { "name": "membershipProfileId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "204": { "description": "No content" } } } }, "/membership_profiles/{membershipProfileId}/organization": { "get": { "operationId": "GET/membershipProfileId/organization", "summary": "Related membership profile", "description": "Related membership profile", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "membershipProfileId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the membership profile" } } } }, "/membership_profiles/{membershipProfileId}/application_memberships": { "get": { "operationId": "GET/membershipProfileId/application_memberships", "summary": "Related membership profile", "description": "Related membership profile", "tags": [ "application_memberships", "has_many" ], "parameters": [ { "name": "membershipProfileId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The application_memberships associated to the membership profile" } } } }, "/organizations": { "post": { "operationId": "POST/organizations", "summary": "Creates an organization", "description": "Creates an organization", "tags": [ "organizations" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationCreate" } } } }, "responses": { "201": { "description": "The created organization object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationResponse" } } } } } }, "get": { "operationId": "GET/organizations", "summary": "List all organizations", "description": "List all organizations", "tags": [ "organizations" ], "responses": { "200": { "description": "A list of organization objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationResponseList" } } } } } } }, "/organizations/{organizationId}": { "get": { "operationId": "GET/organizations/organizationId", "summary": "Retrieve an organization", "description": "Retrieve an organization", "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "organizations" ], "responses": { "200": { "description": "The organization object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationResponse" } } } } } }, "patch": { "operationId": "PATCH/organizations/organizationId", "summary": "Updates an organization", "description": "Updates an organization", "tags": [ "organizations" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationUpdate" } } } }, "responses": { "200": { "description": "The updated organization object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/organizationResponse" } } } } } } }, "/organizations/{organizationId}/transfer_ownership": { "patch": { "operationId": "PATCH/organizations/organizationId/transfer_ownership", "summary": "Transfer ownership of an organization", "description": "Transfers the ownership of an organization to a new owner", "tags": [ "organizations" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "new_owner_email": { "type": "string", "description": "The user email of the new owner of the organization.", "example": "test@commercelayer.io", "nullable": false } } } } } } } } } }, "responses": { "202": { "description": "The confirmation of the transfer ownership", "content": {} } } } }, "/organizations/{organizationId}/memberships": { "get": { "operationId": "GET/organizationId/memberships", "summary": "Related organization", "description": "Related organization", "tags": [ "memberships", "has_many" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The memberships associated to the organization" } } } }, "/organizations/{organizationId}/roles": { "get": { "operationId": "GET/organizationId/roles", "summary": "Related organization", "description": "Related organization", "tags": [ "roles", "has_many" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The roles associated to the organization" } } } }, "/organizations/{organizationId}/permissions": { "get": { "operationId": "GET/organizationId/permissions", "summary": "Related organization", "description": "Related organization", "tags": [ "permissions", "has_many" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The permissions associated to the organization" } } } }, "/organizations/{organizationId}/api_credentials": { "get": { "operationId": "GET/organizationId/api_credentials", "summary": "Related organization", "description": "Related organization", "tags": [ "api_credentials", "has_many" ], "parameters": [ { "name": "organizationId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The api_credentials associated to the organization" } } } }, "/permissions": { "post": { "operationId": "POST/permissions", "summary": "Creates an permission", "description": "Creates an permission", "tags": [ "permissions" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionCreate" } } } }, "responses": { "201": { "description": "The created permission object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionResponse" } } } } } }, "get": { "operationId": "GET/permissions", "summary": "List all permissions", "description": "List all permissions", "tags": [ "permissions" ], "responses": { "200": { "description": "A list of permission objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionResponseList" } } } } } } }, "/permissions/{permissionId}": { "get": { "operationId": "GET/permissions/permissionId", "summary": "Retrieve an permission", "description": "Retrieve an permission", "parameters": [ { "name": "permissionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "permissions" ], "responses": { "200": { "description": "The permission object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionResponse" } } } } } }, "patch": { "operationId": "PATCH/permissions/permissionId", "summary": "Updates an permission", "description": "Updates an permission", "tags": [ "permissions" ], "parameters": [ { "name": "permissionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionUpdate" } } } }, "responses": { "200": { "description": "The updated permission object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/permissionResponse" } } } } } } }, "/permissions/{permissionId}/organization": { "get": { "operationId": "GET/permissionId/organization", "summary": "Related permission", "description": "Related permission", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "permissionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the permission" } } } }, "/permissions/{permissionId}/role": { "get": { "operationId": "GET/permissionId/role", "summary": "Related permission", "description": "Related permission", "tags": [ "roles", "has_one" ], "parameters": [ { "name": "permissionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The role associated to the permission" } } } }, "/permissions/{permissionId}/versions": { "get": { "operationId": "GET/permissionId/versions", "summary": "Related permission", "description": "Related permission", "tags": [ "versions", "has_many" ], "parameters": [ { "name": "permissionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The versions associated to the permission" } } } }, "/roles": { "post": { "operationId": "POST/roles", "summary": "Creates an role", "description": "Creates an role", "tags": [ "roles" ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleCreate" } } } }, "responses": { "201": { "description": "The created role object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleResponse" } } } } } }, "get": { "operationId": "GET/roles", "summary": "List all roles", "description": "List all roles", "tags": [ "roles" ], "responses": { "200": { "description": "A list of role objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleResponseList" } } } } } } }, "/roles/{roleId}": { "get": { "operationId": "GET/roles/roleId", "summary": "Retrieve an role", "description": "Retrieve an role", "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "roles" ], "responses": { "200": { "description": "The role object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleResponse" } } } } } }, "patch": { "operationId": "PATCH/roles/roleId", "summary": "Updates an role", "description": "Updates an role", "tags": [ "roles" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleUpdate" } } } }, "responses": { "200": { "description": "The updated role object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/roleResponse" } } } } } } }, "/roles/{roleId}/organization": { "get": { "operationId": "GET/roleId/organization", "summary": "Related role", "description": "Related role", "tags": [ "organizations", "has_one" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The organization associated to the role" } } } }, "/roles/{roleId}/permissions": { "get": { "operationId": "GET/roleId/permissions", "summary": "Related role", "description": "Related role", "tags": [ "permissions", "has_many" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The permissions associated to the role" } } } }, "/roles/{roleId}/memberships": { "get": { "operationId": "GET/roleId/memberships", "summary": "Related role", "description": "Related role", "tags": [ "memberships", "has_many" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The memberships associated to the role" } } } }, "/roles/{roleId}/api_credentials": { "get": { "operationId": "GET/roleId/api_credentials", "summary": "Related role", "description": "Related role", "tags": [ "api_credentials", "has_many" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The api_credentials associated to the role" } } } }, "/roles/{roleId}/versions": { "get": { "operationId": "GET/roleId/versions", "summary": "Related role", "description": "Related role", "tags": [ "versions", "has_many" ], "parameters": [ { "name": "roleId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "responses": { "200": { "description": "The versions associated to the role" } } } }, "/user": { "get": { "operationId": "GET/user", "summary": "Retrieve an user", "description": "Retrieve an user", "parameters": [], "tags": [ "user", "singleton" ], "responses": { "200": { "description": "The user object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/userResponse" } } } } } }, "patch": { "operationId": "PATCH/user", "summary": "Updates an user", "description": "Updates an user", "tags": [ "user", "singleton" ], "parameters": [], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/userUpdate" } } } }, "responses": { "200": { "description": "The updated user object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/userResponse" } } } } } } }, "/versions": { "get": { "operationId": "GET/versions", "summary": "List all versions", "description": "List all versions", "tags": [ "versions" ], "responses": { "200": { "description": "A list of version objects", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/versionResponseList" } } } } } } }, "/versions/{versionId}": { "get": { "operationId": "GET/versions/versionId", "summary": "Retrieve an version", "description": "Retrieve an version", "parameters": [ { "name": "versionId", "in": "path", "schema": { "type": "string" }, "required": true, "description": "The ID of the resource." } ], "tags": [ "versions" ], "responses": { "200": { "description": "The version object", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/versionResponse" } } } } } } } }, "components": { "schemas": { "apiCredential": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The API credential internal name.", "example": "My app", "nullable": false }, "kind": { "type": "string", "description": "The API credential kind, can be one of: `webapp`, `sales_channel`, `integration` or the kind of app you want to fork (e.g. `orders`, `imports`, etc.).", "example": "sales_channel", "nullable": false }, "confidential": { "type": "boolean", "description": "Indicates if the API credential it's confidential.", "example": true, "readOnly": true }, "redirect_uri": { "type": "string", "description": "The API credential redirect URI.", "example": "https://bluebrand.com/img/logo.svg", "nullable": true }, "client_id": { "type": "string", "description": "The API credential unique ID.", "example": "xxxx-yyyy-zzzz", "readOnly": true }, "client_secret": { "type": "string", "description": "The API credential unique secret.", "example": "xxxx-yyyy-zzzz", "readOnly": true }, "scopes": { "type": "string", "description": "The API credential scopes.", "example": "market:all market:9 market:122 market:6 stock_location:6 stock_location:33", "readOnly": true }, "expires_in": { "type": "integer", "description": "The lifetime of the access token in seconds (min. `7200`, max. `31536000`. Default is `14400` for Sales channels and `7200` for other client types).", "example": 7200, "nullable": true }, "mode": { "type": "string", "description": "Indicates the environment the resource belongs to (one of `test` or `live`).", "example": "test", "nullable": true }, "custom": { "type": "boolean", "description": "Indicates if the API credential is used to create a custom app (e.g. fork a hosted app).", "example": false, "nullable": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "apiCredentialCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The API credential internal name.", "example": "My app" }, "kind": { "type": "string", "description": "The API credential kind, can be one of: `webapp`, `sales_channel`, `integration` or the kind of app you want to fork (e.g. `orders`, `imports`, etc.).", "example": "sales_channel" }, "redirect_uri": { "type": "string", "description": "The API credential redirect URI.", "example": "https://bluebrand.com/img/logo.svg" }, "expires_in": { "type": "integer", "description": "The lifetime of the access token in seconds (min. `7200`, max. `31536000`. Default is `14400` for Sales channels and `7200` for other client types).", "example": 7200 }, "mode": { "type": "string", "description": "Indicates the environment the resource belongs to (one of `test` or `live`).", "example": "test" }, "custom": { "type": "boolean", "description": "Indicates if the API credential is used to create a custom app (e.g. fork a hosted app).", "example": false }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "name", "kind" ] }, "relationships": { "type": "object", "properties": { "organization": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "organization" ] } } } } }, "apiCredentialUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The API credential internal name.", "example": "My app", "nullable": false }, "redirect_uri": { "type": "string", "description": "The API credential redirect URI.", "example": "https://bluebrand.com/img/logo.svg", "nullable": true }, "expires_in": { "type": "integer", "description": "The lifetime of the access token in seconds (min. `7200`, max. `31536000`. Default is `14400` for Sales channels and `7200` for other client types).", "example": 7200, "nullable": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "apiCredentialResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/apiCredential/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "role": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "role" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "apiCredentialResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/apiCredentialResponse/properties/data" } } } }, "applicationMembership": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "attributes": { "type": "object", "properties": { "filters": { "type": "object", "description": "Set of key-value pairs that contains restrictions and scopes of the application membership.", "example": { "market_id_in": [ 202, 203 ] }, "nullable": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "api_credential": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership_profile": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "applicationMembershipCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "attributes": { "type": "object", "properties": { "filters": { "type": "object", "description": "Set of key-value pairs that contains restrictions and scopes of the application membership.", "example": { "market_id_in": [ 202, 203 ] } }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } } }, "relationships": { "type": "object", "properties": { "api_credential": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership_profile": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "organization": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "api_credential", "organization", "role" ] } } } } }, "applicationMembershipUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "filters": { "type": "object", "description": "Set of key-value pairs that contains restrictions and scopes of the application membership.", "example": { "market_id_in": [ 202, 203 ] }, "nullable": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "membership_profile": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "applicationMembershipResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/applicationMembership/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "api_credential": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credential" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "membership": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "membership_profile": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profile" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "role": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "role" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "applicationMembershipResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/applicationMembershipResponse/properties/data" } } } }, "identityProvider": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "identity_providers" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the Identity provider.", "example": "Org auth0", "nullable": false }, "client_id": { "type": "string", "description": "The client ID used for the auth workflow.", "example": "a6CDk5v1ZV99GrtOcfYVEZRnDDt", "nullable": false }, "client_secret": { "type": "string", "description": "The client secret used for the auth workflow.", "example": "s6CD55v1ZV99ArtOcfYVEZRnDDf", "nullable": false }, "issuer": { "type": "string", "description": "The issuer used for the auth workflow.", "example": "https://dev.auth987.com/", "nullable": false }, "status": { "type": "string", "description": "The identity provider status. One of `pending` (default), `verified` or `error`.", "example": "pending", "readOnly": true, "enum": [ "pending", "verified", "error" ] }, "domains": { "type": "string", "description": "The list of domains in scope (comma-separated).", "example": "dev.auth987.com,stg.auth987.com", "nullable": false }, "token_url": { "type": "string", "description": "The token URL used for the auth workflow.", "example": "https://dev.auth987.com/oauth/token", "nullable": false }, "authorize_url": { "type": "string", "description": "The authorize URL used for the auth workflow.", "example": "https://dev.auth987.com/authorize", "nullable": false }, "jwks_url": { "type": "string", "description": "The JWKS key store URL used for the auth workflow.", "example": "https://dev.auth987.com/.well-known/jwks.json", "nullable": false }, "txt_record": { "type": "string", "description": "The TXT record value used to check the domain.", "example": "cl-verification=a6CDk5v", "readOnly": true }, "organization": { "type": "string", "description": "The organization identifier for authorize params.", "example": "org_76gsfs5gd", "nullable": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true }, "disabled_at": { "type": "string", "description": "Time at which this resource was disabled.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true } } }, "relationships": { "type": "object", "properties": { "user": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "users" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "identityProviderCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "identity_providers" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the Identity provider.", "example": "Org auth0" }, "client_id": { "type": "string", "description": "The client ID used for the auth workflow.", "example": "a6CDk5v1ZV99GrtOcfYVEZRnDDt" }, "client_secret": { "type": "string", "description": "The client secret used for the auth workflow.", "example": "s6CD55v1ZV99ArtOcfYVEZRnDDf" }, "issuer": { "type": "string", "description": "The issuer used for the auth workflow.", "example": "https://dev.auth987.com/" }, "domains": { "type": "string", "description": "The list of domains in scope (comma-separated).", "example": "dev.auth987.com,stg.auth987.com" }, "token_url": { "type": "string", "description": "The token URL used for the auth workflow.", "example": "https://dev.auth987.com/oauth/token" }, "authorize_url": { "type": "string", "description": "The authorize URL used for the auth workflow.", "example": "https://dev.auth987.com/authorize" }, "jwks_url": { "type": "string", "description": "The JWKS key store URL used for the auth workflow.", "example": "https://dev.auth987.com/.well-known/jwks.json" }, "organization": { "type": "string", "description": "The organization identifier for authorize params.", "example": "org_76gsfs5gd" }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } }, "_disable": { "type": "boolean", "description": "Send this attribute if you want to mark this resource as disabled.", "example": true }, "_enable": { "type": "boolean", "description": "Send this attribute if you want to mark this resource as enabled.", "example": true } }, "required": [ "name", "client_id", "client_secret", "issuer", "domains", "token_url", "authorize_url", "jwks_url" ] }, "relationships": { "type": "object", "properties": {} } } } } }, "identityProviderUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "identity_providers" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the Identity provider.", "example": "Org auth0", "nullable": false }, "client_id": { "type": "string", "description": "The client ID used for the auth workflow.", "example": "a6CDk5v1ZV99GrtOcfYVEZRnDDt", "nullable": false }, "client_secret": { "type": "string", "description": "The client secret used for the auth workflow.", "example": "s6CD55v1ZV99ArtOcfYVEZRnDDf", "nullable": false }, "issuer": { "type": "string", "description": "The issuer used for the auth workflow.", "example": "https://dev.auth987.com/", "nullable": false }, "domains": { "type": "string", "description": "The list of domains in scope (comma-separated).", "example": "dev.auth987.com,stg.auth987.com", "nullable": false }, "token_url": { "type": "string", "description": "The token URL used for the auth workflow.", "example": "https://dev.auth987.com/oauth/token", "nullable": false }, "authorize_url": { "type": "string", "description": "The authorize URL used for the auth workflow.", "example": "https://dev.auth987.com/authorize", "nullable": false }, "jwks_url": { "type": "string", "description": "The JWKS key store URL used for the auth workflow.", "example": "https://dev.auth987.com/.well-known/jwks.json", "nullable": false }, "organization": { "type": "string", "description": "The organization identifier for authorize params.", "example": "org_76gsfs5gd", "nullable": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true }, "_disable": { "type": "boolean", "description": "Send this attribute if you want to mark this resource as disabled.", "example": true, "nullable": false }, "_enable": { "type": "boolean", "description": "Send this attribute if you want to mark this resource as enabled.", "example": true, "nullable": false } } }, "relationships": { "type": "object", "properties": {} } } } } }, "identityProviderResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "identity_providers" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/identityProvider/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "user": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "user" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "identityProviderResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/identityProviderResponse/properties/data" } } } }, "membership": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "attributes": { "type": "object", "properties": { "user_email": { "type": "string", "description": "The user email.", "example": "commercelayer@commercelayer.io", "nullable": false }, "user_first_name": { "type": "string", "description": "The user first name.", "example": "John", "readOnly": true }, "user_last_name": { "type": "string", "description": "The user last name.", "example": "Doe", "readOnly": true }, "status": { "type": "string", "description": "The memberships status. One of `pending` (default), `active`.", "example": "pending", "readOnly": true, "enum": [ "pending", "active" ] }, "owner": { "type": "boolean", "description": "Indicates if the user it's the owner of the organization.", "example": true, "readOnly": true }, "test_enabled": { "type": "boolean", "description": "Reflects the organization's access scope, either test_access or all_access.", "example": false, "readOnly": true }, "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "nullable": true, "enum": [ "live_access", "test_access", "all_access" ] }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "application_memberships": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership_profile": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "versions": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "membershipCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "attributes": { "type": "object", "properties": { "user_email": { "type": "string", "description": "The user email.", "example": "commercelayer@commercelayer.io" }, "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "enum": [ "live_access", "test_access", "all_access" ] }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "user_email" ] }, "relationships": { "type": "object", "properties": { "organization": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "application_memberships": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership_profile": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "organization", "role" ] } } } } }, "membershipUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "nullable": true, "enum": [ "live_access", "test_access", "all_access" ] }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "application_memberships": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "membership_profile": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "membershipResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/membership/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "role": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "role" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "application_memberships": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "membership_profile": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profile" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "versions": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "membershipResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/membershipResponse/properties/data" } } } }, "membershipProfile": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The membership profile name.", "example": "Marketing group", "nullable": false }, "test_enabled": { "type": "boolean", "description": "Reflects the organization's access scope, either test_access or all_access.", "example": false, "readOnly": true }, "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "nullable": false, "enum": [ "live_access", "test_access", "all_access" ] }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "application_memberships": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "membershipProfileCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The membership profile name.", "example": "Marketing group" }, "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "enum": [ "live_access", "test_access", "all_access" ] }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "name", "access_scope" ] }, "relationships": { "type": "object", "properties": { "organization": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "application_memberships": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "organization" ] } } } } }, "membershipProfileUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The membership profile name.", "example": "Marketing group", "nullable": false }, "access_scope": { "type": "string", "description": "The access scope for applications. One of `live_access` (default), `test_access`, `all_access`.", "example": "live_access", "nullable": false, "enum": [ "live_access", "test_access", "all_access" ] }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "application_memberships": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "membershipProfileResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "membership_profiles" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/membershipProfile/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "application_memberships": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "application_memberships" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "membershipProfileResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/membershipProfileResponse/properties/data" } } } }, "organization": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The organization's internal name.", "example": "The Blue Brand", "nullable": false }, "slug": { "type": "string", "description": "The organization's slug name.", "example": "the-blue-brand", "readOnly": true }, "domain": { "type": "string", "description": "The organization's domain.", "example": "the-blue-brand.commercelayer.io", "readOnly": true }, "support_phone": { "type": "string", "description": "The organization's support phone.", "example": "+01 30800857", "nullable": true }, "support_email": { "type": "string", "description": "The organization's support email.", "example": "support@bluebrand.com", "nullable": true }, "logo_url": { "type": "string", "description": "The URL to the organization's logo.", "example": "https://bluebrand.com/img/logo.svg", "nullable": true }, "favicon_url": { "type": "string", "description": "The URL to the organization's favicon.", "example": "https://bluebrand.com/img/favicon.ico", "nullable": true }, "primary_color": { "type": "string", "description": "The organization's primary color.", "example": "#C8984E", "nullable": true }, "contrast_color": { "type": "string", "description": "The organization's contrast color. Format is HEX (starts with `#` and is followed by six letters and/or numbers).", "example": "#FFFFCC", "nullable": true }, "gtm_id": { "type": "string", "description": "The organization's Google Tag Manager ID.", "example": "GTM-5FJXX6", "nullable": true }, "gtm_id_test": { "type": "string", "description": "The organization's Google Tag Manager ID for test.", "example": "GTM-5FJXX7", "nullable": true }, "region": { "type": "string", "description": "The region where the organization is located. The default value is `eu-west-1`.", "example": "eu-west-1", "nullable": true }, "can_switch_live": { "type": "boolean", "description": "Indicates if the organization can switch to live mode.", "example": false, "readOnly": true }, "subscription_info": { "type": "object", "description": "Information about the current subscription such as the plan type, limits, and subscription totals counter.", "example": { "plan_type": "growth", "limits": { "markets": 5, "skus": 10000, "organizations": 2, "memberships": 5 }, "totals": { "organizations": 1, "markets": 0, "memberships": 2, "skus": 0 } }, "readOnly": true }, "config": { "type": "object", "description": "The organization's configuration.", "example": { "mfe": { "language": "it-IT", "default": { "links": { "cart": "https://cart.example.com/:order_id?accessToken=:access_token", "checkout": "https://checkout.example.com/:order_id?accessToken=:access_token", "identity": "https://example.com/login", "microstore": "https://example.com/microstore/?accessToken=:access_token", "my_account": "https://example.com/my-custom-account?accessToken=:access_token" }, "checkout": { "optional_billing_info": false, "thankyou_page": "https://example.com/thanks/:lang/:order_id", "billing_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "shipping_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "billing_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "shipping_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "default_country": "US" }, "urls": { "privacy": "https://example.com/privacy/:lang", "terms": "https://example.com/terms/:lang" } }, "market:id:ZKcv13rT": { "links": { "cart": "https://example.com/custom-cart/:order_id?accessToken=:access_token" }, "checkout": { "thankyou_page": "https://example.com/thanks/:order_id" } } } }, "nullable": true }, "api_auth_redirect": { "type": "boolean", "description": "Enables the redirect on the new Auth API.", "example": true, "readOnly": true }, "api_rules_engine": { "type": "boolean", "description": "Enables the rules engine for flex promotions and price list rules.", "example": false, "readOnly": true }, "api_rules_engine_max_conditions_size": { "type": "integer", "description": "The fallback maximum number of conditions within a rules payload on a ruleable object, default is 150.", "example": 150, "readOnly": true }, "api_rules_engine_max_rules_size": { "type": "integer", "description": "The fallback maximum number of rules within a rules payload on a ruleable object, default is 15.", "example": 15, "readOnly": true }, "api_new_auth": { "type": "boolean", "description": "Forces the usage of the new Authentication API.", "example": true, "readOnly": true }, "api_purge_single_resource": { "type": "boolean", "description": "Enables the purge of cached single resources when list is purged.", "example": false, "readOnly": true }, "api_max_regex_length": { "type": "integer", "description": "The maximum length for the regular expressions, default is 5000.", "example": 5000, "readOnly": true }, "addresses_avs_check": { "type": "boolean", "description": "Indicates if AVS checking will be enforced during payment workflow by passing specific attributes, default is true.", "example": true, "readOnly": true }, "addresses_phone_required": { "type": "boolean", "description": "Indicates if the phone attribute is required for addresses, default is true.", "example": true, "readOnly": true }, "orders_sales_channel_guest_only": { "type": "boolean", "description": "Indicates if a sales channel application without customer can read and update just guest orders.", "example": true, "readOnly": true }, "orders_min_rebuild_shipments_lapse": { "type": "number", "description": "The minimum lapse in fraction of seconds to be observed between two consecutive shipments rebuilt. If shipments rebuilt is triggered within the minimum lapse, the update is performed, but no rebuilt is done.", "example": 0.0, "readOnly": true }, "orders_min_refresh_lapse": { "type": "number", "description": "The minimum lapse in fraction of seconds to be observed between two consecutive order refreshes. If refresh is triggered within the minimum lapse, the update is performed, but no order refresh is done.", "example": 0.0, "readOnly": true }, "orders_autorefresh_cutoff_test": { "type": "integer", "description": "The maximum number line items allowed for a test order before disabling the autorefresh option.", "example": 50, "readOnly": true }, "orders_autorefresh_cutoff_live": { "type": "integer", "description": "The maximum number line items allowed for a live order before disabling the autorefresh option.", "example": 500, "readOnly": true }, "orders_number_editable_test": { "type": "boolean", "description": "Enables orders number editing as a string in test (for enterprise plans only).", "example": false, "readOnly": true }, "orders_number_editable_live": { "type": "boolean", "description": "Enables orders number editing as a string in live (for enterprise plans only).", "example": false, "readOnly": true }, "orders_number_as_reference": { "type": "boolean", "description": "Enables to use the order number as payment reference on supported gateways.", "example": true, "readOnly": true }, "orders_invalid_coupon_errors": { "type": "boolean", "description": "Enables raising of API errors in case the provided coupon code is invalid, default is true.", "example": true, "readOnly": true }, "orders_invalid_gift_card_errors": { "type": "boolean", "description": "Enables raising of API errors in case the provided gift card code is invalid, default is true.", "example": true, "readOnly": true }, "orders_validate_shipping_stock": { "type": "boolean", "description": "Enables the validation of the generated stock line items and stock transfers before placing the order, default is false.", "example": false, "readOnly": true }, "bundles_max_items_count": { "type": "integer", "description": "The maximum number of SKUs allowed for bundles, default is 10.", "example": 10, "readOnly": true }, "coupons_min_code_length": { "type": "integer", "description": "The minimum length for coupon code, default is 8.", "example": 8, "readOnly": true }, "coupons_max_code_length": { "type": "integer", "description": "The maximum length for coupon code, default is 40.", "example": 40, "readOnly": true }, "gift_cards_exact_code_matching": { "type": "boolean", "description": "Enables matching the gift card code by its exact value, instead of by its first charachters, default is false.", "example": false, "readOnly": true }, "gift_cards_min_code_length": { "type": "integer", "description": "The minimum length for gift card code, default is 8.", "example": 8, "readOnly": true }, "gift_cards_max_code_length": { "type": "integer", "description": "The maximum length for gift card code, default is 40.", "example": 40, "readOnly": true }, "cleanups_max_concurrent_count": { "type": "integer", "description": "The maximum number of concurrent cleanups allowed for your organization, default is 10.", "example": 10, "readOnly": true }, "exports_max_concurrent_count": { "type": "integer", "description": "The maximum number of concurrent exports allowed for your organization, default is 10.", "example": 10, "readOnly": true }, "imports_max_concurrent_count": { "type": "integer", "description": "The maximum number of concurrent imports allowed for your organization, default is 10.", "example": 10, "readOnly": true }, "imports_purge_cache": { "type": "boolean", "description": "Enables purging of cached resources upon succeeded imports.", "example": true, "readOnly": true }, "imports_skip_errors": { "type": "boolean", "description": "Disables the interruption of the import in case its errors exceeds the 10% threshold, default is false.", "example": false, "readOnly": true }, "inventory_models_max_stock_locations_cutoff": { "type": "integer", "description": "The maximum number for stock locations cutoff, default is 10.", "example": 10, "readOnly": true }, "promotions_max_concurrent_count": { "type": "integer", "description": "The maximum number of active concurrent promotions allowed for your organization, default is 10.", "example": 10, "readOnly": true }, "promotions_max_conditions_size": { "type": "integer", "description": "The maximum number of conditions within a rules payload on a promotion object, default is 150.", "example": 150, "readOnly": true }, "promotions_max_rules_size": { "type": "integer", "description": "The maximum number of rules within a rules payload on a promotion object, default is 15.", "example": 15, "readOnly": true }, "price_lists_max_conditions_size": { "type": "integer", "description": "The maximum number of conditions within a rules payload on a price list object, default is 150.", "example": 150, "readOnly": true }, "price_lists_max_rules_size": { "type": "integer", "description": "The maximum number of rules within a rules payload on a price list object, default is 15.", "example": 15, "readOnly": true }, "imports_trigger_webhooks": { "type": "integer", "description": "Enables triggering of webhooks during imports, default is false.", "example": 0, "readOnly": true }, "discount_engines_enabled": { "type": "boolean", "description": "Enables the use of an external discount engine in place of the standard one, default is false.", "example": false, "readOnly": true }, "discount_engines_errors": { "type": "boolean", "description": "Enables raising of API errors in case of discount engine failure, default is false.", "example": false, "readOnly": true }, "tags_max_name_length": { "type": "integer", "description": "The maximum length for the tag name, default is 25.", "example": 25, "readOnly": true }, "tags_max_allowed_number": { "type": "integer", "description": "The maximum allowed number of tags for each resource, default is 10.", "example": 10, "readOnly": true }, "tax_calculators_errors": { "type": "boolean", "description": "Enables raising of API errors in case of tax calculation failure, default is false.", "example": false, "readOnly": true }, "external_promotions_errors": { "type": "boolean", "description": "Enables raising of API errors in case of external promotion failure, default is false.", "example": false, "readOnly": true }, "external_prices_errors": { "type": "boolean", "description": "Enables raising of API errors in case of external price failure, default is true.", "example": true, "readOnly": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "memberships": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "roles": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "permissions": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "api_credentials": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "organizationCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The organization's internal name.", "example": "The Blue Brand" }, "support_phone": { "type": "string", "description": "The organization's support phone.", "example": "+01 30800857" }, "support_email": { "type": "string", "description": "The organization's support email.", "example": "support@bluebrand.com" }, "logo_url": { "type": "string", "description": "The URL to the organization's logo.", "example": "https://bluebrand.com/img/logo.svg" }, "favicon_url": { "type": "string", "description": "The URL to the organization's favicon.", "example": "https://bluebrand.com/img/favicon.ico" }, "primary_color": { "type": "string", "description": "The organization's primary color.", "example": "#C8984E" }, "contrast_color": { "type": "string", "description": "The organization's contrast color. Format is HEX (starts with `#` and is followed by six letters and/or numbers).", "example": "#FFFFCC" }, "gtm_id": { "type": "string", "description": "The organization's Google Tag Manager ID.", "example": "GTM-5FJXX6" }, "gtm_id_test": { "type": "string", "description": "The organization's Google Tag Manager ID for test.", "example": "GTM-5FJXX7" }, "region": { "type": "string", "description": "The region where the organization is located. The default value is `eu-west-1`.", "example": "eu-west-1" }, "config": { "type": "object", "description": "The organization's configuration.", "example": { "mfe": { "language": "it-IT", "default": { "links": { "cart": "https://cart.example.com/:order_id?accessToken=:access_token", "checkout": "https://checkout.example.com/:order_id?accessToken=:access_token", "identity": "https://example.com/login", "microstore": "https://example.com/microstore/?accessToken=:access_token", "my_account": "https://example.com/my-custom-account?accessToken=:access_token" }, "checkout": { "optional_billing_info": false, "thankyou_page": "https://example.com/thanks/:lang/:order_id", "billing_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "shipping_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "billing_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "shipping_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "default_country": "US" }, "urls": { "privacy": "https://example.com/privacy/:lang", "terms": "https://example.com/terms/:lang" } }, "market:id:ZKcv13rT": { "links": { "cart": "https://example.com/custom-cart/:order_id?accessToken=:access_token" }, "checkout": { "thankyou_page": "https://example.com/thanks/:order_id" } } } } }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "name" ] }, "relationships": { "type": "object", "properties": {} } } } } }, "organizationUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The organization's internal name.", "example": "The Blue Brand", "nullable": false }, "support_phone": { "type": "string", "description": "The organization's support phone.", "example": "+01 30800857", "nullable": true }, "support_email": { "type": "string", "description": "The organization's support email.", "example": "support@bluebrand.com", "nullable": true }, "logo_url": { "type": "string", "description": "The URL to the organization's logo.", "example": "https://bluebrand.com/img/logo.svg", "nullable": true }, "favicon_url": { "type": "string", "description": "The URL to the organization's favicon.", "example": "https://bluebrand.com/img/favicon.ico", "nullable": true }, "primary_color": { "type": "string", "description": "The organization's primary color.", "example": "#C8984E", "nullable": true }, "contrast_color": { "type": "string", "description": "The organization's contrast color. Format is HEX (starts with `#` and is followed by six letters and/or numbers).", "example": "#FFFFCC", "nullable": true }, "gtm_id": { "type": "string", "description": "The organization's Google Tag Manager ID.", "example": "GTM-5FJXX6", "nullable": true }, "gtm_id_test": { "type": "string", "description": "The organization's Google Tag Manager ID for test.", "example": "GTM-5FJXX7", "nullable": true }, "config": { "type": "object", "description": "The organization's configuration.", "example": { "mfe": { "language": "it-IT", "default": { "links": { "cart": "https://cart.example.com/:order_id?accessToken=:access_token", "checkout": "https://checkout.example.com/:order_id?accessToken=:access_token", "identity": "https://example.com/login", "microstore": "https://example.com/microstore/?accessToken=:access_token", "my_account": "https://example.com/my-custom-account?accessToken=:access_token" }, "checkout": { "optional_billing_info": false, "thankyou_page": "https://example.com/thanks/:lang/:order_id", "billing_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "shipping_countries": [ { "value": "ES", "label": "Espana" }, { "value": "IT", "label": "Italia" }, { "value": "US", "label": "Unites States of America" } ], "billing_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "shipping_states": { "FR": [ { "value": "PA", "label": "Paris" }, { "value": "LY", "label": "Lyon" }, { "value": "NI", "label": "Nice" }, { "value": "MA", "label": "Marseille" }, { "value": "BO", "label": "Bordeaux" } ] }, "default_country": "US" }, "urls": { "privacy": "https://example.com/privacy/:lang", "terms": "https://example.com/terms/:lang" } }, "market:id:ZKcv13rT": { "links": { "cart": "https://example.com/custom-cart/:order_id?accessToken=:access_token" }, "checkout": { "thankyou_page": "https://example.com/thanks/:order_id" } } } }, "nullable": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "organizationResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/organization/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "memberships": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "roles": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "permissions": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "api_credentials": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "organizationResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/organizationResponse/properties/data" } } } }, "permission": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "attributes": { "type": "object", "properties": { "can_create": { "type": "boolean", "description": "Determines if the permission have access to create rights.", "example": false, "nullable": false }, "can_read": { "type": "boolean", "description": "Determines if the permission have access to read rights.", "example": false, "nullable": false }, "can_update": { "type": "boolean", "description": "Determines if the permission have access to update rights.", "example": false, "nullable": false }, "can_destroy": { "type": "boolean", "description": "Determines if the permission have access to destroy rights.", "example": false, "nullable": false }, "subject": { "type": "string", "description": "The resource where this permission is applied.", "example": "", "nullable": false }, "restrictions": { "type": "object", "description": "An object that contains additional restrictions.", "example": { "foo": "bar" }, "readOnly": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "role": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "versions": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "permissionCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "attributes": { "type": "object", "properties": { "can_create": { "type": "boolean", "description": "Determines if the permission have access to create rights.", "example": false }, "can_read": { "type": "boolean", "description": "Determines if the permission have access to read rights.", "example": false }, "can_update": { "type": "boolean", "description": "Determines if the permission have access to update rights.", "example": false }, "can_destroy": { "type": "boolean", "description": "Determines if the permission have access to destroy rights.", "example": false }, "subject": { "type": "string", "description": "The resource where this permission is applied.", "example": "" }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "can_create", "can_read", "can_update", "can_destroy", "subject" ] }, "relationships": { "type": "object", "properties": { "role": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "role" ] } } } } }, "permissionUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "can_create": { "type": "boolean", "description": "Determines if the permission have access to create rights.", "example": false, "nullable": false }, "can_read": { "type": "boolean", "description": "Determines if the permission have access to read rights.", "example": false, "nullable": false }, "can_update": { "type": "boolean", "description": "Determines if the permission have access to update rights.", "example": false, "nullable": false }, "can_destroy": { "type": "boolean", "description": "Determines if the permission have access to destroy rights.", "example": false, "nullable": false }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "permissionResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/permission/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "role": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "role" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "versions": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "permissionResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/permissionResponse/properties/data" } } } }, "role": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The role name.", "example": "Custom role", "nullable": false }, "kind": { "type": "string", "description": "The kind of role, one of: `custom`, `admin`, `read_only`", "example": "custom", "readOnly": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "permissions": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "memberships": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "api_credentials": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } }, "versions": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } } } } } } }, "roleCreate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The role name.", "example": "Custom role" }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE" }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN" }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" } } }, "required": [ "name" ] }, "relationships": { "type": "object", "properties": { "organization": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organizations" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" } } } } } }, "required": [ "organization" ] } } } } }, "roleUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "id", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "description": "The role name.", "example": "Custom role", "nullable": false }, "_add_missing_base_permissions": { "type": "boolean", "description": "Send this attribute if you want to update the role base permissions.", "example": true, "nullable": false }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "roleResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "roles" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/role/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": { "organization": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "organization" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "permissions": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "permissions" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "memberships": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "memberships" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "api_credentials": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "api_credentials" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } }, "versions": { "type": "object", "properties": { "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" }, "related": { "type": "string", "description": "URL" } } }, "data": { "type": "object", "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "id": { "type": "string", "description": "The ID of the resource." } } } } } } } } } } }, "roleResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/roleResponse/properties/data" } } } }, "user": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "users" ] }, "attributes": { "type": "object", "properties": { "email": { "type": "string", "description": "The user email.", "example": "user@commercelayer.io", "nullable": false }, "first_name": { "type": "string", "description": "The user first name.", "example": "John", "nullable": false }, "last_name": { "type": "string", "description": "The user last name.", "example": "Doe", "nullable": false }, "time_zone": { "type": "string", "description": "The user preferred timezone.", "example": "UTC", "nullable": true }, "otp_required_for_login": { "type": "boolean", "description": "The user 2FA setting.", "example": false, "readOnly": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "userUpdate": { "required": [ "data" ], "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "users" ] }, "attributes": { "type": "object", "properties": { "email": { "type": "string", "description": "The user email.", "example": "user@commercelayer.io", "nullable": false }, "first_name": { "type": "string", "description": "The user first name.", "example": "John", "nullable": false }, "last_name": { "type": "string", "description": "The user last name.", "example": "Doe", "nullable": false }, "time_zone": { "type": "string", "description": "The user preferred timezone.", "example": "UTC", "nullable": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "userResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "users" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/user/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": {} } } } } }, "userResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/userResponse/properties/data" } } } }, "version": { "type": "object", "properties": { "data": { "type": "object", "required": [ "type", "attributes" ], "properties": { "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "attributes": { "type": "object", "properties": { "resource_type": { "type": "string", "description": "The type of the versioned resource.", "example": "roles", "readOnly": true }, "resource_id": { "type": "string", "description": "The versioned resource ID.", "example": "PzdJhdLdYV", "readOnly": true }, "event": { "type": "string", "description": "The event which generates the version.", "example": "update", "readOnly": true }, "changes": { "type": "object", "description": "The object changes payload.", "example": { "name": [ "previous", "new" ] }, "readOnly": true }, "who": { "type": "object", "description": "Information about who triggered the change, only showed when it's from a JWT token.", "example": { "application": { "id": "DNOPYiZYpn", "kind": "integration", "public": true } }, "readOnly": true }, "created_at": { "type": "string", "description": "Time at which the resource was created.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "updated_at": { "type": "string", "description": "Time at which the resource was last updated.", "example": "2018-01-01T12:00:00.000Z", "readOnly": true }, "reference": { "type": "string", "description": "A string that you can use to add any external identifier to the resource. This can be useful for integrating the resource to an external system, like an ERP, a marketing tool, a CRM, or whatever.", "example": "ANY-EXTERNAL-REFEFERNCE", "nullable": true }, "reference_origin": { "type": "string", "description": "Any identifier of the third party system that defines the reference code.", "example": "ANY-EXTERNAL-REFEFERNCE-ORIGIN", "nullable": true }, "metadata": { "type": "object", "description": "Set of key-value pairs that you can attach to the resource. This can be useful for storing additional information about the resource in a structured format.", "example": { "foo": "bar" }, "nullable": true } } }, "relationships": { "type": "object", "properties": {} } } } } }, "versionResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of the resource.", "example": "XGZwpOSrWL" }, "type": { "type": "string", "description": "The resource's type.", "enum": [ "versions" ] }, "links": { "type": "object", "properties": { "self": { "type": "string", "description": "URL" } } }, "attributes": { "$ref": "#/components/schemas/version/properties/data/properties/attributes" }, "relationships": { "type": "object", "properties": {} } } } } }, "versionResponseList": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/versionResponse/properties/data" } } } } }, "securitySchemes": { "bearerAuth": { "type": "http", "scheme": "bearer", "bearerFormat": "JWT" } } }, "tags": [ { "name": "singleton", "description": "singleton resource" }, { "name": "api_credentials", "description": "resource type" }, { "name": "has_one", "description": "relationship kind" }, { "name": "application_memberships", "description": "resource type" }, { "name": "identity_providers", "description": "resource type" }, { "name": "memberships", "description": "resource type" }, { "name": "has_many", "description": "relationship kind" }, { "name": "membership_profiles", "description": "resource type" }, { "name": "organizations", "description": "resource type" }, { "name": "permissions", "description": "resource type" }, { "name": "roles", "description": "resource type" }, { "name": "users", "description": "resource type" }, { "name": "versions", "description": "resource type" } ], "security": [ { "bearerAuth": [] } ] }