---
title: "Update the specified contract"
method: PATCH
path: "/contracts/{contract_id}"
tags: ["contracts"]
---

# Update the specified contract

`PATCH /contracts/{contract_id}`

For updating Contract name this request is authorized to the users with `contracts.contract.edit` permission.

For updating the set of available roles of the particular Contract this request is authorized to the user with
`contracts.contract.edit_available_roles` permission.

For updating the custom data this request is authorized to the users with `contracts.contract.edit_custom_data`
permission.

For updating the feature flags this request is authorized to the users with `tenants.contract.edit_feature_flags`
permission.

For updating the type this request is authorized to the users with `tenants.contract.edit_type`
permission.

## Path parameters

- `contract_id` string, required

## Request body

- object
  - `data` object, required
    - `id` string, required — Contract identifier. It has to match the identifier specified in the path.
    - `type` 'contract', required — Allowed value `contract`.
    - `attributes` object, required
      - `name` string, required — Name of the contract
      - `type` 'full' | 'trial' — Type of the contract.
      - `created_at` string — Shows the creation date of a contract.
      - `updated_at` string — Shows the date of last update made to the contract.
      - `available_roles` object[]
        - `scope` 'contracts' | 'workspaces', required — The role's scope
        - `role` string, required — The role's name
      - `status` string
      - `flow_stats_enabled_default` boolean
      - `support_user_id` string — An identifier of user from platform support team
      - `custom_data` object — Custom contract data in an arbitrary format. This field is **not intended to store sensitive data**. Max size after stringify is 1 MB
      - `feature_flags` object
        - `disable_recipe_feature` boolean — Disable ability to change existing recipes or create new ones
        - `subscribe_to_error_by_default` boolean — Subscribe to error notifications from flows by default. Default: "true"

## Response `200`

OK

- object
  - `data` object, required
    - `id` string, required
    - `type` 'contract', required — Allowed value: `contract`
    - `links` object, required
      - `self` string, required
    - `attributes` object, required
      - `name` string, required — Name of the contract
      - `type` 'full' | 'trial' — Type of the contract.
      - `created_at` string — Shows the creation date of a contract.
      - `updated_at` string — Shows the date of last update made to the contract.
      - `available_roles` object[]
        - `scope` 'contracts' | 'workspaces', required — The role's scope
        - `role` string, required — The role's name
      - `status` string
      - `flow_stats_enabled_default` boolean
      - `support_user_id` string — An identifier of user from platform support team
      - `custom_data` object — Custom contract data in an arbitrary format. This field is **not intended to store sensitive data**. Max size after stringify is 1 MB
      - `feature_flags` object
        - `disable_recipe_feature` boolean — Disable ability to change existing recipes or create new ones
        - `subscribe_to_error_by_default` boolean — Subscribe to error notifications from flows by default. Default: "true"
    - `relationships` object, required
      - `members` object, required
        - `data` object[], required
          - `id` string, required
          - `type` 'contract-member', required
        - `links` object, required
          - `self` string, required
      - `workspaces` object, required
        - `data` object[], required
          - `id` string, required
          - `type` 'workspace', required
      - `invites` object, required
        - `data` object[], required
          - `id` string, required
          - `type` 'contract-invite', required
        - `links` object, required
          - `self` string, required
  - `meta` object, required

## Other responses

- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found

---

[API](https://skmtc.net/elastic/apis/elastic-io-rest-api-documentation-v2.md) · [All operations](https://skmtc.net/elastic/apis/elastic-io-rest-api-documentation-v2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/elastic/elastic-io-rest-api-documentation-v2/revisions/411f9f98c01e/schema)
