Document Properties
Kbid
29T598
Last Modified
09-Nov-2022
Added to KB
03-Sep-2020
Public Access
Everyone
Status
Online
Doc Type
References
Product
  • ICM 7.10
  • ICM 11
Reference - Contract REST API 1.0.0
Document View


This API specification is available for download as an Open API 3.0 YAML file: 

References

The following page lists available REST APIs for ICM 7.10 and their version dependencies:

API Specification

Introduction
OpenAPI Version: 3.0.1
Contract Management Version: 1.0.0

The Intershop Contract Management API contains operations that allow to retrieve contract information.

In an Intershop context, a contract is a relationship between a merchant and a business customer and serves as a frame for a defined set of catalogs and catalog items, including corresponding price lists and promotions.

Contract API

The following operations for retrieving contract information are available:

/customers/{CustomerKey}/contracts
GET: Returns customer contracts

Description

This operation returns a list of all contracts of a business customer. A user of the respective business customer must be authenticated.
If pageable is null, a new pageable will be used and its ID returned to the caller.

Java Method

public com.intershop.component.rest.capi.resourceobject.ResourceCollectionRO com.intershop.application.storefront.rest.b2b.capi.resource.CustomerContractsResource.listContracts(java.lang.String,java.lang.Integer,java.lang.Integer)

Request Body

--

Request Parameters

LocationNameFormatDefaultExampleDescription
in pathCustomerKeystringOilCorpRequired | The customer ID
in querypageablestringzVsKCgoEZ90AAAF1Og4DHYjuThe pageable ID
in queryoffsetinteger int322The offset to start the contract listing at
in queryamountinteger int325The count of contracts to be returned

Response

200 - OK - The list of contracts for the given customer.

ResourceCollectionROLinkRO application/json
ResourceCollectionROLinkRO -> elements -> [..] -> itemId can be used as {CustomerContractKey} in subsequent requests. Links to item of type CustomerContractRO.

401 - Unauthorized - The user could not be authenticated.

404 - Not Found - The customer could not be found.

/customers/{CustomerKey}/contracts/{CustomerContractKey}
GET: Returns customer contract details

Description

This operation returns details of a customer contract. A user of the respective business customer must be authenticated. The return attributes for the current and the target revenue are specific for the contract type RevenueBased. Other contract types are not supported.

Java Method

public com.intershop.application.storefront.rest.b2b.capi.resourceobject.CustomerContractRO com.intershop.application.storefront.rest.b2b.capi.resource.CustomerContractItemResource.getContract()

Request Body

--

Request Parameters

LocationNameFormatDefaultExampleDescription
in pathCustomerKeystringOilCorpRequired | The customer ID
in pathCustomerContractKeystring85cKCgoE5yoAAAF1ut8DHYjoRequired | The contract UUID

Response

200 - OK - The contract with the given ID.

CustomerContractRO application/json

401 - Unauthorized - The user could not be authenticated.

403 - Forbidden - The authenticated user does not belong to the requested customer.

404 - Not Found - The customer or the contract could not be found.

/customers/{CustomerKey}/contracts/{CustomerContractKey}/orders
GET: Returns customer contract orders

Description

This operation returns a pageable list of orders of a customer contract. A user of the respective business customer must be authenticated.

Java Method

public com.intershop.component.rest.capi.resourceobject.ResourceCollectionRO com.intershop.application.storefront.rest.b2b.capi.resource.CustomerContractOrdersResource.listOrders()

Request Body

--

Request Parameters

LocationNameFormatDefaultExampleDescription
in pathCustomerKeystringOilCorpRequired | The customer ID
in pathCustomerContractKeystring85cKCgoE5yoAAAF1ut8DHYjoRequired | The contract UUID

Response

200 - OK - The list of orders for the given contract.

ResourceCollectionROLinkRO application/json

401 - Unauthorized - The user could not be authenticated.

403 - Forbidden - The authenticated user does not belong to the requested customer.

404 - Not Found - The customer or the contract could not be found.

Request and Response Object Schemata
CustomerContractRO application/json{
  • "name":
    string
    The name of an element
  • "type":
    string
    The type of the element. This is normally a constant that can be used to differentiate elements by their type. | Example: Contract
  • "attributes":
    array
    An array of ResourceAttribute objects. The list of attributes
    [
    ResourceAttribute: An attribute
    {
    • "name":
      string
      The attribute's name
    • "type":
      string
      This is a constant: ResourceAttribute | Example: ResourceAttribute
    • "value":
      object
      The attribute's value.
    }
    ]
  • "displayName":
    string
    The display name of the contract | Example: 10% rebate on all graphics cards
  • "description":
    string
    The description of the contract | Example: This contract grants 10% rebate on all graphics cards.
  • "contractType":
    string
    The type of the contract | Example: RevenueBased
  • "startDate":
    string
    The start date of the contract in the ISO date-time format yyyy-MM-dd'T'HH:mm:ss
  • "endDate":
    string
    The end date of the contract in the ISO date-time format yyyy-MM-dd'T'HH:mm:ss
  • "currentRevenue":
    object
    A MoneyRO object. Money combines a currency and a money amount.
    {
    • "type":
      string
      Readonly | This is a constant: Money | Example: Money
    • "value":
      number
      The monetary value. | Example: 10.99
    • "currencyMnemonic":
      string
      Deprecated
    • "currency":
      string
      Three-letter currency code (ISO 4217) of the monetary value. | Example: USD
    }
  • "targetRevenue":
    object
    A MoneyRO object. Money combines a currency and a money amount.
    {
    • "type":
      string
      Readonly | This is a constant: Money | Example: Money
    • "value":
      number
      The monetary value. | Example: 10.99
    • "currencyMnemonic":
      string
      Deprecated
    • "currency":
      string
      Three-letter currency code (ISO 4217) of the monetary value. | Example: USD
    }
  • "id":
    string
    The ID of the contract | Example: ZEcKDgBj5cEAAAFPlMgclI6M
  • "attribute":
    object
    A ResourceAttribute object. An attribute
    {
    • "name":
      string
      The attribute's name
    • "type":
      string
      This is a constant: ResourceAttribute | Example: ResourceAttribute
    • "value":
      object
      The attribute's value.
    }
}
ResourceCollectionROLinkRO application/json{
  • "pageable":
    string
    The pageable ID.
  • "total":
    integer
    The pageable amount total | Format: int32
  • "offset":
    integer
    The pageable offset | Format: int32
  • "amount":
    integer
    The pageable amount | Format: int32
  • "elements":
    array
    An array of LinkRO objects. The list of elements
    [
    LinkRO: A Link pointing to a resource
    {
    • "name":
      string
      The name of the returned element
    • "type":
      string
      Readonly | This is a constant: Link | Example: Link
    • "attributes":
      array
      An array of ResourceAttribute objects. The list of attributes
      [
      ResourceAttribute: An attribute
      {
      • "name":
        string
        The attribute's name
      • "type":
        string
        This is a constant: ResourceAttribute | Example: ResourceAttribute
      • "value":
        object
        The attribute's value.
      }
      ]
    • "uri":
      string
      The URI
    • "relation":
      string
      The relation of the link | Documentation: Link Relations (www.iana.org) | Possible Values: aboutalternateappendixarchivesauthorbookmarkcanonicalchaptercollectioncontentscopyrightcreate-formcurrentdescribedbydescribesdisclosureduplicateeditedit-formedit-mediaenclosurefirstglossaryhelphostshubiconindexitemlastlatest-versionlicenselrddmonitormonitor-groupnextnext-archivenofollownoreferrerpaymentpredecessor-versionprefetchprevpreviewpreviousprev-archiveprivacy-policyprofilerelatedrepliessearchsectionselfservicestartstylesheetsubsectionsuccessor-versiontagterms-of-servicetypeupversion-historyviaworking-copyworking-copy-of
    • "title":
      string
      The title of the link
    • "description":
      string
      The description of the link
    • "itemId":
      string
      The ID of the linked item
    • "attribute":
      object
      A ResourceAttribute object. An attribute
      {
      • "name":
        string
        The attribute's name
      • "type":
        string
        This is a constant: ResourceAttribute | Example: ResourceAttribute
      • "value":
        object
        The attribute's value.
      }
    }
    ]
  • "type":
    string
    This is a constant: ResourceCollection | Example: ResourceCollection
  • "sortKeys":
    array
    An array of string literals. The keys to sort for
  • "name":
    string
    The name of the returned element
}
Disclaimer
The information provided in the Knowledge Base may not be applicable to all systems and situations. Intershop Communications will not be liable to any party for any direct or indirect damages resulting from the use of the Customer Support section of the Intershop Corporate Web site, including, without limitation, any lost profits, business interruption, loss of programs or other data on your information handling system.
The Intershop Knowledge Portal uses only technically necessary cookies. We do not track visitors or have visitors tracked by 3rd parties. Please find further information on privacy in the Intershop Privacy Policy and Legal Notice.
Home
Knowledge Base
Product Releases
Log on to continue
This Knowledge Base document is reserved for registered customers.
Log on with your Intershop Entra ID to continue.
Write an email to supportadmin@intershop.de if you experience login issues,
or if you want to register as customer.