Skip to main content

Punchout

Punchout API enables users to initiate an OCI punchout to a product on Amazon.

Endpoint

POST /api/v1/amazon/product/{id}/punchout HTTP/1.1
Accept: application/json

Initiate an OCI punchout to a specific product on Amazon Business.

Parameters

ParameterInTypeRequiredDescription
idpathstringtrueID of the product to punchout

Request Body

The request body is a JSON object.

ParameterTypeRequiredDescription
callbackUrlstringtrueHOOK_URL of the OCI punchout process. This URL will always be used, even in failure; in other words, we try everything to pass control back to the caller.
namestringfalseFull name of the requester, e.g. "Joe Average". It is being used e.g. in shipping notifications
shipToobject(Address)falseShipment address (see below). If it is not specified here, Amazon may fallback to using the default address of the group/organization, which more often than not is a bad idea.

Example:

{
"callbackUrl": "https://example.com/oci/callback",
"name": "Joe Average",
"shipTo": {
"street": "525 Market St",
"city": "San Francisco",
"postalCode": "94105",
"state": "CA",
"countryCode": "US",
"country": "United States of America"
}
}

Shipment address

The parameters of the shipment address are the same as those in the cXML specification.

ParameterDescription
addressId(optional) ID of the address.
addressIdDomain(optional) Domain of the address ID.
street(optional) Street.
cityCode(optional) City code.
city(optional) City name.
stateCode(optional) State code.
state(optional) State.
postalCode(optional) Postal code.
countryCode(optional) Country code, e.g. US.
country(optional) Country name.

Response

Overview

StatusMeaningDescription
201CreatedA response structure to use for OCI punchout.
400Bad RequestThe server understood your request but is unable to complete it, e.g. because a required parameter is missing.
401UnauthorizedYou sent invalid or expired credentials.
404Not FoundThe product, catalog, or vendor wasn't found.
429Too Many RequestsThe server received too many requests in a given amount of time; you should throttle down and retry later.
500Internal Server ErrorSomething went wrong on our side.

Response schema

Status Code 201

NameTypeRequiredDescription
redirectUrlstringtrueThe URL to start the OCI punchout process

Examples

201 response
{
"redirectUrl": "https://www.amazon.com/eprocurement/initiate-clean-punchout/123-4567890-1234567"
}