Existing customer? log in now
This video is embedded in YouTube/s extended data protection mode, which blocks the setting of YouTube cookies until you actively click on playback. By clicking on the play button, you give your consent for YouTube to set cookies on the end device you are using, which can also be used to analyze usage behavior for market research and marketing purposes. You can find more information about the use of cookies by YouTube in Google/s cookie policy at https://policies.google.com/technologies/types?hl=de.
Receive orders from different cXML customers and define your own data format for our REST API. Attention: This function is currently only available to selected customers as part of our Enterprise contracts.
Order profiles are the core of our order module. Here you have the option of defining your own data model and make it available via a REST API. An order profile can be assigned to one or more customers.
To do this, first switch to the Order profiles area and click on "Create new order profile". Now you have You now have the option of assigning a name to your profile and uploading a cXML file of the type "OrderRequest".
In the next step, you create a data model for your order profile. proposal based on the cXML data model for each new order profile.
Procurement systems such as Ariba® or Coupa can be configured so that new orders from your customers are sent as a cXML-OrderRequest to the address below. The address is identical for all your customers and uses the normal authentication of the cXML standard.
https://<instance>.enterprise.punchcommerce.com/api/v1/orders/cxml
The endpoint expects a cXML-OrderRequest document according to the specification in chapter 7 of the cXML-Reference Guide.
Important: The receipt of orders is only possible for customers to whom you have assigned an order profile. Orders for unknown customers or customers without a profile are automatically rejected and are not available for processing via our API. not available for processing via our API.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE cXML SYSTEM "http://xml.cxml.org/schemas/cXML/1.2.014/cXML.dtd">
<cXML xml:lang="en-US" payloadID="93369535150910.10.57.136" timestamp="2000-08-03T08:49:11+07:00">
<Header>
<From>
<Credential domain="AribaNetworkUserId">
<Identity>admin@acme.com</Identity>
</Credential>
</From>
<To>
<Credential domain="DUNS">
<Identity>114315195</Identity>
</Credential>
</To>
<Sender>
<Credential domain="AribaNetworkUserId">
<Identity>sysadmin@ariba.com</Identity>
<SharedSecret>abracadabra</SharedSecret>
</Credential>
<UserAgent>Network Hub V1.1</UserAgent>
</Sender>
</header>
<Request>
<OrderRequest>
<OrderRequestHeader orderID="DO102880" orderDate="2012-08-03T08:49:09+07:00" type="new">
<Total>
<Money currency="USD">86.50</Money>
</Total>
<ShipTo>
<Address isoCountryCode="US" addressID="1000467">
<Name xml:lang="en">Acme, Inc.</Name>
<PostalAddress name="default">
<DeliverTo>John Q. Smith</DeliverTo>
<DeliverTo>Buyers Headquarters</DeliverTo>
<Street>123 Main Street</Street>
<City>Mountain View</City>
<State isoStateCode="US-CA">CA</State>
<PostalCode>94089</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email name="default">john_smith@acme.com</Email>
<Phone name="work">
<TelephoneNumber>
<CountryCode isoCountryCode="US">1</CountryCode>
<AreaOrCityCode>800</AreaOrCityCode>
<Number>5555555</Number>
</TelephoneNumber>
</Phone>
</Address>
</ShipTo>
<BillTo>
<Address isoCountryCode="US" addressID="12">
<Name xml:lang="en">Acme Accounts Payable</Name>
<PostalAddress name="default">
<Street>124 Union Street</Street>
<City>San Francisco</City>
<State isoStateCode="US-CA">CA</State>
<PostalCode>94128</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Phone name="work">
<TelephoneNumber>
<CountryCode isoCountryCode="US">1</CountryCode>
<AreaOrCityCode>415</AreaOrCityCode>
<Number>6666666</Number>
</TelephoneNumber>
</Phone>
</Address>
</BillTo>
<LegalEntity>
<IdReference domain="CompanyCode" identifier="CH01">
<Description>SAP AG</Description>
</IdReference>
</LegalEntity>
<OrganisationalUnit>
<IdReference domain=" PurchasingOrganisation" identifier="SCP">
<Description> SCPM Purchasing Org </Description>
</IdReference>
</OrganisationalUnit>
<OrganisationalUnit>
<IdReference domain=" PurchasingGroup" identifier="0001">
<Description> PGP Buyer </Description>
</IdReference>
</OrganisationalUnit>
<Shipping>
<Money currency="USD">10.00</Money>
<Description xml:lang="en-US">FedEx 2-day</Description>
</Shipping>
<Tax>
<Money currency="USD">1.5</Money>
<Description xml:lang="en">CA State Tax</Description>
</Tax>
<Payment>
<PCard number="1234567890123456" expiration="2015-03-12"/>
</Payment>
</OrderRequestHeader>
<ItemOut quantity="2" lineNumber="1">
<ItemID>
<SupplierPartID>220-3165</SupplierPartID>
<SupplierPartAuxiliaryID>E000028901</SupplierPartAuxiliaryID>
</ItemID>
<ItemDetail>
<UnitPrice>
<Money currency="USD">55.00</Money>
<Modifications>
<Modification>
<OriginalPrice>
<Money currency = "USD">50.00</Money>
</OriginalPrice>
<AdditionalCost>
<Money currency = "USD">5</Money>
</AdditionalCost>
<ModificationDetail endDate = "2013-11-30T10:15:00-08:00" name = "Royalties" startDate = "2012-08-03T10:15:00-08:00">
<Description xml:lang = "en-US">Charge for Royalties</Description>
</ModificationDetail>
</Modification>
</Modifications>
</UnitPrice>
<Description xml:lang="en">Laptop Computer Notebook Pentium® II
processor w/AGP, 300 MHz, with 12.1" TFT XGA
Display</Description>
<UnitOfMeasure>EA</UnitOfMeasure>
<Classification domain="UNSPSC">43171801</Classification>
<URL>http://www.supplier.com/Punchout.asp</URL>
<Extrinsic name="ExtDescription">Enhanced keyboard</Extrinsic>
</ItemDetail>
<Distribution>
<Accounting name="DistributionCharge">
<AccountingSegment id="7720">
<Name xml:lang="en-US">Account</Name>
<Description xml:lang="en-US">Office Supplies
</Description>
</AccountingSegment>
<AccountingSegment id="610">
<Name xml:lang="en-US">Cost Centre</Name>
<Description xml:lang="en-US">Engineering Management
</Description>
</AccountingSegment>
</Accounting>
<Charge>
<Money currency="USD">20.00</Money>
</Charge>
</Distribution>
</ItemOut>
</OrderRequest>
</Request>
</cXML>
If no error occurs when processing the order, our system responds with the following (example) response as confirmation of receipt of the order. receipt of the order. No commercial obligation arises in this step.
<cXML payloadID="9949494" xml:lang="en"
timestamp="1999-03-12T18:39:09-08:00">
<Response>
<status code="200" text="OK"/>
</response>
</cXML>
Individual access data in the form of a token and a URL for our REST API is generated for each order profile.
List of all orders in a profile
Query a list of all orders received:
GET {{punchcommerce_host}}/api/v1/profile/{{profile_id}}
Response:
{
"data": {
"id": "4a152855-1a26-4059-a637-4d56cc151d9e",
"name": "adsd",
"customers": [
{
"uuid": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"name": "Mraz Inc"
}
],
"orders": [
{
"id": "cb074373-60d9-4c1b-9453-988602da457e",
"customer_id": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"customer": "Mraz Inc",
"created_at": "2022-10-03T13:21:16.000000Z",
"link": "https://punchcommerce.local/api/v1/profile/4a152855-1a26-4059-a637-4d56cc151d9e/order/cb074373-60d9-4c1b-9453-988602da457e"
},
{
"id": "b8f7e5e1-b4da-4bc6-b4b1-7f2e85d3b99d",
"customer_id": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"customer": "Mraz Inc",
"created_at": "2022-10-03T13:20:29.000000Z",
"link": "https://punchcommerce.local/api/v1/profile/4a152855-1a26-4059-a637-4d56cc151d9e/order/b8f7e5e1-b4da-4bc6-b4b1-7f2e85d3b99d"
},
{
"id": "f09473fc-876b-4005-bd7e-df8bdd53ccbc",
"customer_id": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"customer": "Mraz Inc",
"created_at": "2022-10-03T13:12:15.000000Z",
"link": "https://punchcommerce.local/api/v1/profile/4a152855-1a26-4059-a637-4d56cc151d9e/order/f09473fc-876b-4005-bd7e-df8bdd53ccbc"
},
{
"id": "e7eed80a-6d0d-4657-8d85-ae4e4c9f13ae",
"customer_id": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"customer": "Mraz Inc",
"created_at": "2022-09-19T09:43:09.000000Z",
"link": "https://punchcommerce.local/api/v1/profile/4a152855-1a26-4059-a637-4d56cc151d9e/order/e7eed80a-6d0d-4657-8d85-ae4e4c9f13ae"
},
{
"id": "3b379913-77a0-441a-af57-d45308a94738",
"customer_id": "69f14942-178d-4d57-b6d5-fdd9d4aee407",
"customer": "Mraz Inc",
"created_at": "2022-09-19T09:43:07.000000Z",
"link": "https://punchcommerce.local/api/v1/profile/4a152855-1a26-4059-a637-4d56cc151d9e/order/3b379913-77a0-441a-af57-d45308a94738"
}
]
}
Details of an order
Please note that the response to this request depends on the data model that you have configured in our system for the associated order profile. order profile in our system.
{{punchcommerce_host}}/api/v1/profile/{{profile_id}}/order/{{order_id}}
Example response:
{
"data": {
"meta": {
"request_id": "1637737323553.569506334.000002897@IrwnYChEL2oZa48FesaJ62+R18I=",
"cxml_version": "1.2.044",
"language": "en-US"
},
"order": {
"total": "17",
"currency": "EUR",
"date": "2021-11-23T23:01:59-08:00",
"reference": "EP686328",
"version": 1,
"billing": {
"company": "FOOBAR GMBH - RECHNUNGSPRUEFUNG",
"street": "Walter-Flex-Str. 27",
"zip": "24000",
"city": "Hamburg",
"country": "Germany"
},
"shipping": {
"company": "FOOBAR GMBH",
"street": "Walter-Flex-Str. 27",
"zip": "65428",
"city": "Rüsselsheim",
"country": "Germany"
},
"items": [
{
"index": 1,
"ordernumber": "FOOBAR_VK-deutsch_up",
"quantity": 100,
"name": "FOOBAR Business Card (German)",
"unit_price": "0.17",
"unit": "EA"
}
]
}
}