Contracts AI

Ironclad integration

Connect Ironclad with OAuth, import contracts, configure webhooks for automatic sync, and map fields in both directions between Ironclad and Contracts.ai.

Contracts.ai can import contracts from Ironclad, keep them in sync via webhooks, analyze documents with AI, and push enriched metadata back to Ironclad when field mappings are configured.

Open AdminIntegrations tab → Ironclad to manage the connection. After you connect, the panel has three tabs:

TabPurpose
ConnectionOAuth credentials, import options, webhooks, and selective import
Outgoing Field MappingMap Contracts.ai fields → Ironclad fields (for push sync)
Incoming Field MappingMap Ironclad fields → Contracts.ai fields (applied on import)

Safe to connect first: Connecting to Ironclad does not automatically import contracts. You can verify the connection, configure mappings, and choose when data flows into Contracts.ai.


Prerequisites

  • An Ironclad admin who can create API apps under Company SettingsAPI
  • A Contracts.ai organization administrator
  • (Optional) Webhook scopes if you want automatic sync when workflows complete in Ironclad

How to set up the Ironclad OAuth app

  1. In Ironclad, go to Company SettingsAPI and click Create new app. Name it Contracts.ai (or similar).
  2. Copy the Client ID and Client Secret from Ironclad. They are only shown once in Ironclad, so save them before leaving the page.
  3. In the Ironclad app settings, set Grant Type to Client Credentials and add these scopes:
ScopeWhy it's needed
public.records.readRecordsFetch and display your Ironclad contracts
public.records.createRecordsCreate new contract records in Ironclad
public.records.updateRecordsUpdate contract metadata and fields
public.records.createSmartImportRecordsImport existing contracts via Ironclad Smart Import
public.records.readAttachmentsDownload contract documents for analysis
public.records.createAttachmentsUpload processed documents back to Ironclad
public.records.readSchemasRead record schemas to map fields correctly
public.records.applyContractActionTrigger workflow actions on contracts
public.webhooks.createWebhooksRegister webhooks for automatic contract syncing
public.webhooks.readWebhooksCheck existing webhooks to avoid duplicates
public.webhooks.updateWebhooksUpdate webhook endpoints when reconnecting
public.webhooks.deleteWebhooksClean up webhooks when disconnecting

Webhook scopes are only required for Automatic Sync (Webhooks). You can add them later in Ironclad and reconnect in Contracts.ai if you start without them.

  1. In the Contracts.ai Connection tab, enter:
    • Client ID
    • Client Secret
    • Ironclad User Email — the email associated with your Ironclad account (used for API context)
    • Region — match your Ironclad instance:
      • North America 1 (na1)
      • North America 2 (na2)
      • Europe (eu)
      • Australia (au)
      • Demo (demo)
  2. Click Connect to IronClad.

When connection succeeds, you’ll see IronClad connected successfully! with connection details (user email and region).


Connection tab — importing contracts

After connecting, use the Connection tab to control how contracts enter Contracts.ai.

Bulk import

Use Import Contracts to start a background import of Ironclad records.

Optional filters (apply before clicking import):

  • Import Limit — cap how many contracts are imported (e.g. 10, 25, 50). Leave blank to import all matching records.
  • Record Types — check one or more Ironclad record types to include. Leave all unchecked to import every type.

Imports run in the background. Contracts appear in your contracts list after processing and AI analysis complete (may take several minutes depending on volume).

Search & import specific contracts

Use Browse & Select Contracts to cherry-pick individual records:

  1. Open the search dialog.
  2. Search by name, type, status, or record ID.
  3. Paste multiple IDs (one per line or comma-separated) to look up specific records at once.
  4. Select the contracts you want and click Import Selected.

Search index (recommended for large repos):

  • The dialog shows whether a local index has been built.
  • If the index is not built, searches query Ironclad live and may be slower.
  • Click Build Index (or Re-sync after a prior build) to index your Ironclad records for faster search. Indexing runs in the background and may take a few minutes for large repositories.

Automatic sync (webhooks)

If you included the webhook scopes when creating the Ironclad app:

  1. On the Connection tab, find Automatic Sync (Webhooks).
  2. Click Enable Automatic Sync to register webhooks with Ironclad.
  3. When active, new or updated contracts can sync automatically when workflows complete in Ironclad—without a manual import.

You can Remove Webhook later to disable automatic sync. If you initially connected without webhook scopes, add them in Ironclad, then reconnect and enable automatic sync.


Outgoing Field Mapping (push to Ironclad)

Use Outgoing Field Mapping to define how Contracts.ai metadata is written back to Ironclad when you sync a contract.

Set up outgoing mappings

  1. Go to AdminIntegrationsIroncladOutgoing Field Mapping.
  2. Select an Ironclad Record Type.
  3. Click Load Field Suggestions to load field IDs seen on existing Ironclad records for that type. You can also type Ironclad field IDs directly.
  4. Create mappings:
    • Your Field (Contracts.ai standard or custom metadata) → Ironclad Field
    • Set the Ironclad field type when needed to avoid type-mismatch errors on sync (String, Date, Boolean, Number, Monetary, Duration).
    • Optionally expand Regex transform to pattern-match and reshape values before sending to Ironclad.
  5. Click Add Mapping for each row.
  6. (Optional) Click Suggest with AI after loading field suggestions—AI proposes mappings you can review and edit.
  7. Click Save Mappings.

Outgoing mappings are required before you can push data from a contract back to Ironclad.


Incoming Field Mapping (import from Ironclad)

Use Incoming Field Mapping to copy Ironclad record properties into Contracts.ai fields when records are imported or synced from Ironclad.

Set up incoming mappings

  1. Go to AdminIntegrationsIroncladIncoming Field Mapping.
  2. Select an Ironclad Record Type.
  3. Click Load Field Suggestions.
  4. Create mappings:
    • Ironclad FieldYour Field (standard or custom)
    • Set Type when needed.
    • Override AI — when enabled, the mapped Ironclad value takes precedence over AI extraction for that field on import/sync.
  5. Click Add Mapping for each row.
  6. Click Save Mappings.

Incoming mappings are applied automatically during Ironclad import and webhook sync. If you newly enable Override AI on a mapping, Contracts.ai can back-fill that field on existing Ironclad-imported contracts in the background.


Regex transforms (outgoing and incoming)

Both Outgoing Field Mapping and Incoming Field Mapping support an optional Regex transform on each mapping row. Regex runs after the source value is read and before it is written to the target field or sent to Ironclad.

Regex uses Python-style re.sub: the Pattern is searched in the source string, and matches are replaced with the Replacement string.

Where to configure it

DirectionTabUI location
Outgoing (Contracts.ai → Ironclad)Outgoing Field MappingExpand Regex transform under a mapping row
Incoming (Ironclad → Contracts.ai)Incoming Field MappingExpand Regex transform under a mapping row

If Pattern is empty, the value is left unchanged (no transform).

Fields

FieldDescription
PatternRegular expression to match (required for the transform to run)
ReplacementText to substitute for each match. Use capture groups with $1 or \1
FlagsOptional: i = case-insensitive, s = dot matches newlines, m = multiline

Outgoing transforms (push to Ironclad)

When you Sync to Ironclad, Contracts.ai:

  1. Reads the value from your Contracts.ai field.
  2. Applies the row’s transform (if configured).
  3. Sends the result to the mapped Ironclad property.

Regex (outgoing)
Use when the Contracts.ai value needs cleanup or reshaping before Ironclad accepts it.

Example — extract a numeric amount from payment terms:

  • Your Field: payment_terms
  • Ironclad Field: contractValue
  • Pattern: USD\s*([\d,.]+)
  • Replacement: $1
  • Flags: i

If payment_terms is "USD 1,250,000 per year", Ironclad receives 1,250,000.

Automatic date formatting (outgoing only)
When you map a date Contracts.ai field to Ironclad, the UI may auto-apply a date format transform (YYYY-MM-DD) instead of regex. You can still switch a row to regex if you need custom parsing.

Other outgoing transforms (backend)
The push pipeline also supports transforms such as value mapping and duration parsing, but the admin UI exposes regex explicitly on each row. Date fields get automatic date formatting when appropriate.

Invalid patterns
If the pattern is invalid, the sync logs a warning and sends the original string unchanged (sync does not fail solely because of a bad regex).

Incoming transforms (import from Ironclad)

When a record is imported or synced from Ironclad, Contracts.ai:

  1. Reads the Ironclad property value.
  2. Normalizes it (e.g. unwraps structured Ironclad values to a scalar).
  3. Applies Regex transform if Pattern is set.
  4. Coerces the result to your target field type (standard or custom).
  5. Writes to the mapped Contracts.ai field (when Override AI is enabled for that row, or on a forced re-apply).

Regex (incoming)
Use when the raw Ironclad value must be cleaned before it fits your field.

Example — strip a currency prefix from an Ironclad monetary field:

  • Ironclad Field: annualContractValue
  • Your Field: custom field budget_code
  • Pattern: ^[A-Z]{3}\s*
  • Replacement: `` (empty)
  • Flags: i

Override AI and regex
Incoming mappings only write on import/sync when Override AI is on for that row (unless an admin force-applies mappings to an existing contract). Regex runs as part of that write path—it does not change AI analysis itself; it changes what gets stored from Ironclad when the mapping applies.

Tips

  • Test regex on one contract before saving org-wide mappings.
  • Use Flags → i when matching text regardless of case.
  • Use capture groups when Ironclad stores extra text around the value you need.
  • For outgoing sync, set the Ironclad field type correctly; regex output must still match what Ironclad expects (string, number, date, etc.).
  • Clear Pattern to disable the transform without deleting the row.

Quick reference

OutgoingIncoming
Runs whenSync to IroncladImport / webhook sync (and bulk re-apply for new Override AI rows)
SourceContracts.ai field valueIronclad property value
Config keyspattern, replacement, flags (under Regex transform)Same
Also auto-appliedDate format on date source fields
If pattern invalidOriginal value sent unchangedOriginal normalized value used unchanged

Pushing data back to Ironclad

After outgoing field mappings are saved, users with the right permissions can push enhanced metadata from Contracts.ai to Ironclad.

Permission required

Users need the Sync to Source System permission (sync_to_source) to see and use the sync action on contract details.

How to sync a contract

  1. Open a contract that was imported from Ironclad (linked via ironclad:// source identity or an Ironclad source URL).
  2. Click Sync to Ironclad in the contract toolbar (or overflow menu on smaller layouts).
  3. Contracts.ai builds a payload from your outgoing field mappings and updates the corresponding Ironclad record.
  4. The UI shows sync status and when the last push occurred (success or warning).

If mappings are missing or no fields resolve, sync returns an error asking you to configure Outgoing Field Mapping first.

Note: Sync pushes metadata fields configured in outgoing mappings. It does not replace the full Ironclad workflow; it updates mapped properties on the linked record.


Disconnecting Ironclad

On the Connection tab, click Disconnect to remove the Ironclad connection and clean up webhooks (when configured).

  • Already-imported contracts remain in Contracts.ai.
  • OAuth credentials are removed from the integration.
  • Field mapping configuration may be retained in your organization settings—verify behavior after disconnect if you plan to reconnect.

Typical workflows

Test connection, then import a small batch

  1. Connect with OAuth (no import yet).
  2. Set Import Limit to 10.
  3. Click Import Contracts and verify contracts appear and analyze correctly.
  4. Configure Incoming Field Mapping if you need Ironclad properties on custom fields.
  5. Scale up with bulk import, record-type filters, or webhooks.

Keep Ironclad and Contracts.ai metadata aligned

  1. Configure Incoming Field Mapping so imports populate key fields from Ironclad.
  2. Let AI analysis enrich the contract in Contracts.ai.
  3. Configure Outgoing Field Mapping for fields you want written back.
  4. Users with Sync to Source System permission push updates with Sync to Ironclad.

Large repository: selective import

  1. Build Index in the search dialog.
  2. Search or paste record IDs.
  3. Import only the contracts you need.

Troubleshooting

IssueWhat to check
Connect failsClient ID/secret, region, and Client Credentials grant type in Ironclad
No record types in dropdownConnection scopes include readSchemas / readRecords; reconnect after fixing scopes
Import started but no contractsBackground job still running; check import limits and record-type filters
Slow searchBuild or re-sync the search index
Webhooks not firingWebhook scopes added in Ironclad; Enable Automatic Sync shows Active
Sync to Ironclad missingUser lacks Sync to Source System permission, or contract was not imported from Ironclad
Sync fails with mapping errorComplete Outgoing Field Mapping; verify Ironclad field IDs and types
Incoming values wrongReview Incoming Field Mapping; use Override AI where Ironclad should win over AI

  • Custom Fields — create targets for incoming mappings and sources for outgoing mappings.
  • Field Label Customization — affects how field names appear in mapping UIs.
  • Roles & Permissions — grant Sync to Source System to users who should push metadata to Ironclad.
  • Contract Types / Gold Standard — Ironclad can also feed contract type reference data in separate admin workflows.

Summary

The Ironclad integration is a three-part setup: connect (OAuth), import (bulk, selective, or webhook-driven), and map fields in both directions. Outgoing mappings power Sync to Ironclad on individual contracts; incoming mappings populate Contracts.ai automatically when records arrive from Ironclad.

Did this answer your question?