# SpotDraft

> Create, upload, send and void contracts in SpotDraft, read their status, approvals, signers and metadata, manage obligations and counterparties, and follow contracts as they move to signature and execution.

App · 25 actions. Web page: https://docs.lodol.com/docs/integrations/spotdraft

## Actions

### Add contract comment

Add a comment to a contract's activity log.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Comment (`comment`, text, required): The comment.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "author": {
      "email": "example",
      "id": 1,
      "name": "example"
    },
    "comment": "example",
    "contract_id": 1,
    "created": "example",
    "id": 1,
    "modified": "example",
    "replies": [
      {
        "author": {
          "email": "example",
          "id": 1,
          "name": "example"
        },
        "comment": "example",
        "created": "example",
        "id": 1,
        "modified": "example"
      }
    ]
  }
}
```

### Archive counterparty

Archive a counterparty so it is no longer offered for new contracts. Its contracts stay.

**Inputs**

- Counterparty (`counterparty_id`, number, required): The counterparty.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "brand_name": "example",
    "contacts": [
      {
        "email": "example",
        "id": 1,
        "name": "example"
      }
    ],
    "custom_fields": {},
    "id": 1,
    "is_individual": true,
    "name": "example",
    "primary_address": {
      "city_name": "example",
      "country_name": "example",
      "email": "example",
      "id": 1,
      "line_one": "example",
      "phone": "example",
      "state_name": "example",
      "zipcode": "example"
    },
    "status": "example"
  }
}
```

### Create contract from template

Create a contract from one of your SpotDraft templates, filled in with your values, for one counterparty.

**Inputs**

- Template (`template_id`, number, required): The template to create the contract from.
- Contract data (`contract_data`, object, required): The template's fields and their values, by field name, such as {"customer_name": "Acme Inc.", "agreement_date": "2026-03-28"}. Dates are YYYY-MM-DD; amounts are {"type": "USD", "value": 12000}.
- Contract name (`contract_name`, text): A name for the contract. Leave empty for SpotDraft's default name.
- Counterparty is a person (`counterparty_is_individual`, true/false): On when the counterparty is a person rather than an organization.
- Counterparty organization (`counterparty_organization_name`, text): The counterparty organization's name. Needed unless the counterparty is a person.
- Contact first name (`contact_first_name`, text, required): The first name of the counterparty's contact (or of the person).
- Contact last name (`contact_last_name`, text): The contact's last name.
- Contact email (`contact_email`, text, required): The contact's email.
- Send to counterparty (`send_to_counterparty`, true/false): On sends the contract to the counterparty as soon as it is created.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "contract_id": 1,
    "contract_link": "example",
    "contract_name": "example",
    "contract_status": "example",
    "contract_type_id": 1,
    "contract_type_name": "example",
    "counter_party_name": "example",
    "created": "example",
    "created_by": "example",
    "created_by_user_email": "example",
    "created_by_user_name": "example",
    "external_metadata": {
      "id": "example",
      "integration_name": "example",
      "record_data": {},
      "record_type": "example"
    },
    "id": "example",
    "reference_id": "example"
  }
}
```

### Create counterparty

Add an organization or a person your workspace has contracts with.

**Inputs**

- Is a person (`is_individual`, true/false, required): On when the counterparty is a person rather than an organization.
- Organization name (`organization_name`, text): The organization's name. Needed unless it is a person.
- Contact name (`contact_name`, text): The contact's full name (or the person's).
- Contact email (`contact_email`, text): The contact's email (or the person's).
- Brand name (`brand_name`, text): The name it trades under, if it differs.
- Street address (`address_line`, text): The street address.
- City (`city`, text): The city. Needed with a street address.
- State (`state`, text): The state or province.
- Postal code (`zipcode`, text): The postal code.
- Country code (`country_code`, text): The country's two-letter code, such as US or GB.
- Custom fields (`custom_fields`, object): Your workspace's own counterparty fields and their values, such as {"vendor_id": "1234"}.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "brand_name": "example",
    "contacts": [
      {
        "email": "example",
        "id": 1,
        "name": "example"
      }
    ],
    "custom_fields": {},
    "id": 1,
    "is_individual": true,
    "name": "example",
    "primary_address": {
      "city_name": "example",
      "country_name": "example",
      "email": "example",
      "id": 1,
      "line_one": "example",
      "phone": "example",
      "state_name": "example",
      "zipcode": "example"
    },
    "status": "example"
  }
}
```

### Create obligation

Record an obligation on a contract, such as a payment, a renewal notice or a delivery, with its due date.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Obligation type (`obligation_type_id`, number, required): The kind of obligation.
- Title (`title`, text, required): A short title.
- Due (`end_date`, date and time, required): When it is due.
- Priority (`priority`, text, required): How important it is. One of: `LOW`, `MEDIUM`, `HIGH`.
- Description (`description`, text): What has to be done.
- Starts (`start_date`, date and time): When it starts.
- Status (`status`, text): Its status. Leave empty for pending. One of: `PENDING`, `COMPLETED`, `FAILED`, `VERIFIED`.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "custom_fields": {},
    "description": "example",
    "end_date": "example",
    "entity_id": 1,
    "id": 1,
    "obligation_type_id": 1,
    "start_date": "example",
    "status": "example",
    "title": "example"
  }
}
```

### Delete obligation

Delete an obligation from a contract.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Obligation (`obligation_id`, number, required): The obligation.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "deleted": true,
    "obligation_id": 1
  }
}
```

### Get contract approvals

Get a contract's approvals, who each is with, its status and what approvers did.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "results": [
      {
        "approval": {
          "approval_name": "example",
          "approval_type": "example",
          "contract_id": 1,
          "created_by_org_user": {
            "email": "example",
            "id": 1,
            "name": "example"
          },
          "id": 1,
          "last_sent_at": "example",
          "notes": "example",
          "org_user": {
            "email": "example",
            "id": 1,
            "name": "example"
          },
          "sent_for_approval": true,
          "status": "example"
        },
        "approval_actions": [
          {
            "created": "example",
            "latest": true,
            "notes": "example",
            "status": "example"
          }
        ]
      }
    ]
  }
}
```

### Get contract download link

Get a short-lived link to download the contract's current version.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Format (`format`, text): The file format. Leave empty for SpotDraft's default. One of: `PDF`, `DOCX` (Word (DOCX)), `DOCX_WITH_FALLBACK_TO_PDF` (Word, or PDF when there is no Word file).

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "current_version_id": 1,
    "file_name": "example",
    "url": "example"
  }
}
```

### Get contract metadata

Get the values of a contract's metadata fields, such as its dates, amounts and terms.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.

**Outputs**

- `data` (list): The response from SpotDraft.

**Example output**

```json
{
  "data": [
    {
      "data_type": "example",
      "field_name": "example",
      "id": 1,
      "label": "example",
      "value": "example"
    }
  ]
}
```

### Get contract recipients

Get a contract's signatories, approvers and receivers, and whether each has finished.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "recipient": {
          "created": "example",
          "id": 1,
          "is_sent_for_signature": true,
          "last_sent_for_signature_at": "example",
          "note": "example",
          "recipient_order": 1,
          "recipient_type": "example",
          "title": "example",
          "user": {
            "designation": "example",
            "email": "example",
            "id": 1,
            "name": "example"
          }
        },
        "recipient_action": {
          "action_notes": "example",
          "is_success": true,
          "timestamp": "example"
        },
        "status": "example"
      }
    ]
  }
}
```

### Get contract status

Get a contract's name and where it is: draft, redlining, out for signature, executed, on hold or voided.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "contract_name": "example",
    "contract_status": "example"
  }
}
```

### Get counterparty

Get a counterparty with its contacts and address.

**Inputs**

- Counterparty (`counterparty_id`, number, required): The counterparty.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "brand_name": "example",
    "contacts": [
      {
        "email": "example",
        "id": 1,
        "name": "example"
      }
    ],
    "custom_fields": {},
    "id": 1,
    "is_individual": true,
    "name": "example",
    "primary_address": {
      "city_name": "example",
      "country_name": "example",
      "email": "example",
      "id": 1,
      "line_one": "example",
      "phone": "example",
      "state_name": "example",
      "zipcode": "example"
    },
    "status": "example"
  }
}
```

### List contract comments

List the comments on a contract's activity log, newest first, with their replies.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Results per page (`limit`, number): How many to return on a page, up to 100. Leave empty for SpotDraft's default of 10. From 1 to 100.
- Page (`page`, number): The page to return, starting at 1. Leave empty for the first. At least 1.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "limit": 1,
    "page": 1,
    "results": [
      {
        "author": {
          "email": "example",
          "id": 1,
          "name": "example"
        },
        "comment": "example",
        "contract_id": 1,
        "created": "example",
        "id": 1,
        "modified": "example",
        "replies": [
          {
            "author": {
              "email": "example",
              "id": 1,
              "name": "example"
            },
            "comment": "example",
            "created": "example",
            "id": 1,
            "modified": "example"
          }
        ]
      }
    ],
    "total_results": 1
  }
}
```

### List contract types

List the workspace's contract types, such as NDA or MSA.

**Inputs**: None.

**Outputs**

- `data` (list): The response from SpotDraft.

**Example output**

```json
{
  "data": [
    {
      "id": 1,
      "name": "example"
    }
  ]
}
```

### List contracts

List or search the workspace's contracts, newest first unless you choose another order.

**Inputs**

- Search (`query`, text): Words to find in the contract name, entity, counterparty name or counterparty email.
- Status (`status`, text): Only contracts in this status. One of: `DRAFT`, `REDLINING` (Redlining (with the counterparty)), `SIGN` (Out for signature), `EXECUTED`, `ON_HOLD` (On hold), `VOIDED`.
- Contract type (`contract_type_id`, number): Only contracts of this type.
- Counterparty name (`counterparty_name`, text): Only contracts with this counterparty name, exactly.
- Created after (`created_after`, date and time): Only contracts created at or after this time.
- Created before (`created_before`, date and time): Only contracts created at or before this time.
- Order (`sort`, text): The order to list them in. Leave empty for newest first. One of: `-filter__created_at` (Newest first), `filter__created_at` (Oldest first), `-filter__last_updated_on` (Most recently changed first), `filter__expiring_at` (Expiring soonest first), `-filter__execution_date` (Most recently executed first).
- Results per page (`limit`, number): How many to return on a page, up to 100. Leave empty for SpotDraft's default of 10. From 1 to 100.
- Page (`page`, number): The page to return, starting at 1. Leave empty for the first. At least 1.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "limit": 1,
    "page": 1,
    "results": [
      {
        "contract_link": "example",
        "contract_name": "example",
        "contract_status": "example",
        "contract_type_id": 1,
        "contract_type_name": "example",
        "counter_party_name": "example",
        "created": "example",
        "created_by": "example",
        "created_by_user_email": "example",
        "created_by_user_name": "example",
        "external_metadata": {
          "id": "example",
          "integration_name": "example",
          "record_data": {},
          "record_type": "example"
        },
        "id": "example",
        "reference_id": "example"
      }
    ],
    "total_results": 1
  }
}
```

### List counterparties

List the organizations and people your workspace has contracts with.

**Inputs**

- Name (`name`, text): Only the counterparty with this name, exactly.
- Contact email (`email`, text): Only counterparties with this contact email.
- Status (`status`, text): Only active or only archived counterparties. Leave empty for both. One of: `ACTIVE`, `ARCHIVED`.
- Results per page (`limit`, number): How many to return on a page, up to 100. Leave empty for SpotDraft's default of 10. From 1 to 100.
- Page (`page`, number): The page to return, starting at 1. Leave empty for the first. At least 1.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "limit": 1,
    "page": 1,
    "results": [
      {
        "brand_name": "example",
        "contacts": [
          {
            "email": "example",
            "id": 1,
            "name": "example"
          }
        ],
        "custom_fields": {},
        "id": 1,
        "is_individual": true,
        "name": "example",
        "primary_address": {
          "city_name": "example",
          "country_name": "example",
          "email": "example",
          "id": 1,
          "line_one": "example",
          "phone": "example",
          "state_name": "example",
          "zipcode": "example"
        },
        "status": "example"
      }
    ],
    "total_results": 1
  }
}
```

### List obligation types

List the kinds of obligation the workspace uses, such as payment or renewal.

**Inputs**: None.

**Outputs**

- `data` (list): The response from SpotDraft.

**Example output**

```json
{
  "data": [
    {
      "description": "example",
      "id": 1,
      "name": "example"
    }
  ]
}
```

### List obligations

List a contract's obligations: what each side has to do, by when, and its status.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.

**Outputs**

- `data` (list): The response from SpotDraft.

**Example output**

```json
{
  "data": [
    {
      "custom_fields": {},
      "description": "example",
      "end_date": "example",
      "entity_id": 1,
      "id": 1,
      "obligation_type_id": 1,
      "start_date": "example",
      "status": "example",
      "title": "example"
    }
  ]
}
```

### List templates

List the templates contracts can be created from.

**Inputs**

- Counterparty kind (`counterparty_type`, text): Only templates for this kind of counterparty. One of: `Organisation` (Organization), `Individual`.
- Include archived (`include_archived`, true/false): On includes archived templates.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "items": [
      {
        "contract_type_id": 1,
        "id": 1,
        "name": "example"
      }
    ]
  }
}
```

### List users

List the people in your SpotDraft workspace, with their roles.

**Inputs**

- Email (`email`, text): Only the user with this email.
- Name starts with (`name`, text): Only users whose full name starts with this.
- Results per page (`limit`, number): How many to return on a page, up to 100. Leave empty for SpotDraft's default of 10. From 1 to 100.
- Page (`page`, number): The page to return, starting at 1. Leave empty for the first. At least 1.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "limit": 1,
    "page": 1,
    "results": [
      {
        "designation": "example",
        "email": "example",
        "id": 1,
        "is_active": true,
        "name": "example",
        "roles": [
          {
            "description": "example",
            "id": 1,
            "name": "example"
          }
        ]
      }
    ],
    "total_results": 1
  }
}
```

### Send contract to counterparties

Email a contract to its counterparties for review, as Word, PDF or both.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Attach as (`attachment_formats`, list, required): The formats to attach the contract in. One or more of: `PDF`, `DOCX` (Word (DOCX)), `TEMPLATE`.
- To (`to_emails`, list): Who to send it to. Leave empty for the counterparty contacts on the contract.
- Cc (`cc_emails`, list): Who to copy.
- Bcc (`bcc_emails`, list): Who to blind copy.
- Subject (`subject`, text): The email's subject.
- Message (`custom_message`, text): A message for the counterparty.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "contract_id": "example",
    "sent": true
  }
}
```

### Update counterparty

Rename a counterparty or change its brand name or custom fields. Fields left empty stay as they are.

**Inputs**

- Counterparty (`counterparty_id`, number, required): The counterparty.
- Name (`name`, text): The new name.
- Brand name (`brand_name`, text): The new brand name.
- Custom fields (`custom_fields`, object): Custom fields to set, by name.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "brand_name": "example",
    "contacts": [
      {
        "email": "example",
        "id": 1,
        "name": "example"
      }
    ],
    "custom_fields": {},
    "id": 1,
    "is_individual": true,
    "name": "example",
    "primary_address": {
      "city_name": "example",
      "country_name": "example",
      "email": "example",
      "id": 1,
      "line_one": "example",
      "phone": "example",
      "state_name": "example",
      "zipcode": "example"
    },
    "status": "example"
  }
}
```

### Update obligation

Change an obligation's title, dates, priority or status, such as marking it completed. Fields left empty stay as they are.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Obligation (`obligation_id`, number, required): The obligation.
- Title (`title`, text): The new title.
- Status (`status`, text): The new status. One of: `PENDING`, `COMPLETED`, `FAILED`, `VERIFIED`.
- Due (`end_date`, date and time): The new due date.
- Starts (`start_date`, date and time): The new start date.
- Priority (`priority`, text): The new priority. One of: `LOW`, `MEDIUM`, `HIGH`.
- Description (`description`, text): The new description.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "custom_fields": {},
    "description": "example",
    "end_date": "example",
    "entity_id": 1,
    "id": 1,
    "obligation_type_id": 1,
    "start_date": "example",
    "status": "example",
    "title": "example"
  }
}
```

### Upload executed contract

Add a contract that is already signed to SpotDraft's repository, from its PDF.

**Inputs**

- PDF file (`file`, text, required): The signed contract, a PDF of up to 25 MB.
- Contract name (`contract_name`, text, required): The name people see for the contract in SpotDraft.
- Contract type (`contract_type_id`, number, required): The contract type.
- File name (`file_name`, text): The file's name in SpotDraft, ending .pdf. Leave empty to keep the uploaded file's name.
- Your entity (`entity_id`, number): Your organization entity that signed it. Leave empty for your primary entity.
- Counterparty is a person (`counterparty_is_individual`, true/false): On when the counterparty is a person rather than an organization.
- Counterparty organization (`counterparty_organization_name`, text): The counterparty organization's name. Needed unless the counterparty is a person.
- Contact first name (`contact_first_name`, text): The first name of the counterparty's contact (or of the person).
- Contact last name (`contact_last_name`, text): The contact's last name.
- Contact email (`contact_email`, text): The contact's email.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "contract_link": "example",
    "contract_name": "example",
    "contract_status": "example",
    "contract_type_id": 1,
    "contract_type_name": "example",
    "counter_party_name": "example",
    "created": "example",
    "created_by": "example",
    "created_by_user_email": "example",
    "created_by_user_name": "example",
    "external_metadata": {
      "id": "example",
      "integration_name": "example",
      "record_data": {},
      "record_type": "example"
    },
    "id": "example",
    "reference_id": "example"
  }
}
```

### Void contract

Void a contract so nobody can sign or change it, with a note saying why.

**Inputs**

- Contract (`contract_id`, text, required): The contract, by its SpotDraft ID such as T-123.
- Note (`note`, text, required): Why the contract is voided. It is kept with the contract.

**Outputs**

- `data` (object): The response from SpotDraft.

**Example output**

```json
{
  "data": {
    "contract_id": "example",
    "voided": true
  }
}
```
