Skip to main content

Create an SAP S/4HANA Purchase Contract from an Ironclad Contract

This article goes over how to automatically create purchase contracts in SAP S/4HANA from Ironclad records. Once configured, an archived contract in Ironclad automatically creates a Purchase Contract (outline agreement) in S/4HANA, with vendor, pricing, terms, and line item data pre-populated.

Use Case

Your procurement team negotiates and executes purchase agreements in Ironclad, but downstream purchasing activity runs in SAP S/4HANA. Contract sync allows Ironclad to automatically create a purchase contract (outline agreement) in S/4HANA when a selected record type is archived. This record carries over key contract attributes such as supplier, company code, purchasing organization, validity dates, and line items.

Prerequisites

Features

Integrations, APIS

Connected Systems

  • SAP Ariba

  • SAP products required for integration:

    • SAP Ariba Procurement

    • SAP Ariba Sourcing

    • SAP Ariba Contracts

    • SAP Ariba Supplier Lifecycle and Performance (Supplier Management)

    • SAP Ariba Developer Portal

Packages

SAP Procurement Automation

Permissions

Admins or users with Integrations Management permissions.

⚙︎

Enable/Access: This feature is available as part of the SAP Procurement Automation package. If you're interested in enabling or purchasing the SAP Procurement Automation package, please contact your Ironclad representative or reach out to our Support team.

Step 1: Configure the Connection Settings

To connect Ironclad to your S/4HANA instance:

  1. In Ironclad, click your profile icon in the top right corner and select Company Settings.

  2. Click Integrations from the left sidebar menu.

  3. Under the Enterprise Resource Planning section, click S/4HANA.

  4. Click the Connection Settings tab.

  5. Under BTP Integration Suite, fill out the connection fields:

    • Instance URL: Your BTP integration Suite instance URL.

    • Token URL: The OAuth token endpoint for your BTP instance.

    • S/4HANA Host: The host name of your S/4HANA instance.

    • SAP BTP Client ID and SAP BTP Client Secret: The OAuth client credentials for your BTP instance.

  6. Click Link.

View Screenshot: S/4HANA Integration Connection Settings

Step 2: Configure Contract Syncing in Ironclad

To configure your contract sync settings:

  1. On the S/4HANA integration page, click the Contract Sync tab.

  2. Click +Add Contract Configuration and select the Ironclad record type to sync.

    • Note: Archived records of this type are created in S/4HANA as purchase contracts.

  3. Under Sync "Record Type", click Edit.

    sync-record-type.png
  4. Under Document Type, check Set a document type and enter the S/4HANA purchase contract document type code (e.g., MK for a quantity contract or WK for a value contract). The document type specifies what header levels are required.

    • Note: When this box isn't checked, the S/4HANA instance default document type is used.

    document-type-sap-s4hana.png
  5. Under Attribute Mapping, map record properties to fields in the S/4HANA purchase contract, including the supplier ID.

  6. For each S/4HANA field, use the Pick a field from Ironclad Record dropdown to select the source property.

    • Note: Some attributes, such as the supplier ID, are required. Records can't be synced to S/4HANA until all required attributes are mapped.

  7. Click Save.

i

Note:

Monetary properties are mapped through their nested fields. For example, to map Target Value, select Pick a field from a nested object field in Ironclad Record, choose your contractValue (MonetaryAmount) property, and then select Amount.

View Example: S/4HANA Attribute Mapping

S/4HANA Purchase Contract Field

Ironclad Record Property

Supplier (Supplier)

ERP Vendor ID

Company Code (CompanyCode)

ERP Company Code

Purch. Organization (PurchasingOrganization)

Purchasing Organization

Purchasing Group (PurchasingGroup)

Purchasing Group

Currency (DocumentCurrency)

Currency

Payment Terms (PaymentTerms)

Payment Terms

Validity Period End (ValidityEndDate)

Expiration Date

Target Value (PurchaseContractTargetAmount)

contractValue (Monetary Amount) > Amount

i

Note:

Payment terms values must match a valid payment terms code in your SAP environment (e.g., NT30 for net 30 terms).

Step 3: Map Line Items

Line items are mapped from a workflow table, so that each row in the table becomes one line item on the purchase contract.

⚠

Warning: S/4HANA requires at least one line item to create the purchase contract, so a record without a mapped line item won't sync.

To map your line items:

  1. Under Attribute Mapping, select to_PurchaseContractItem.

    • Note: This is the name of the field on the S/4HANA purchase contract that holds its line items.

  2. Click Construct an object using fields from Ironclad Record.

  3. For the results array, click Construct an object list from another object list in Ironclad Record.

  4. Select the workflow table that contains your line items.

    • Note: The dropdown lists all tables across your workflows that match the selected record type, so choose the table holding your line items (e.g., Line Items Basic).

  5. Map each line item field to a column from your table using the Pick a field from [Table Name] dropdown.

  6. Click Save.

i

Note:

S/4HANA numbering requires line item numbers to be in increments of 10.

Once your configuration is saved, completing a contract of this record type in Ironclad automatically creates the matching purchase contract in S/4HANA. When the contract syncs, each row in the table becomes one line item on the purchase contract.


View the Purchase Contract in S/4HANA

Once contract sync is configured, Ironclad automatically creates the corresponding purchase contract in S/4HANA when a contract of the configured record type is archived.

To view the purchase contract in S/4HANA:

  1. Launch a workflow of the configured record type, complete it, and archive it.

    • Note: Archiving the workflow creates the record that syncs to S/4HANA.

  2. From the Dashboard, hover over the archived record and click the Preview button.

  3. In overview side panel, scroll down to External links.

  4. Click View in S/4HANA to be taken to the purchase contract.

From now on, each archived contract of this record type creates its own purchase contract in S/4HANA automatically.


Resources

Explore articles, courses, and support options to get the most out of Ironclad.

Help Center

Support

Did this answer your question?