latestOpenAPI 3.0.02026-08-0819201.1 MB

411f9f98c01e

contracts

Returns the specified contract.

You need to be a member of specified contract or a user with TenantAdmin role to access this resource.

To make custom data to be included in a response, a user must have contracts.contract.get_custom_data permission.

get/contracts/{contract_id}

Path parameters

contract_idstring required

Contract identifier

Query parameters

include'members' | 'invites' | 'members,invites'

Include full resource objects in response for related entities, or not. Possible values: members and/or invites

Response

OK

metaobject required

Example response

{
  "data": {
    "id": "5b4f337bff4304610483ba67",
    "links": {
      "self": "/v2/contracts/5b4f337bff4304610483ba67"
    },
    "attributes": {
      "name": "Contract name",
      "available_roles": [
        {
          "role": "admin"
        }
      ],
      "status": "active",
      "support_user_id": "5b4f337bff4304610483ba67",
      "feature_flags": {
        "disable_recipe_feature": true,
        "subscribe_to_error_by_default": true
      }
    },
    "relationships": {
      "members": {
        "data": [
          {
            "id": "5b4f337bff4304610483ba67"
          }
        ],
        "links": {
          "self": "/v2/contracts/5b4f337bff4304610483ba67/members"
        }
      },
      "workspaces": {
        "data": [
          {
            "id": "5b4f337bff4304610483ba67"
          }
        ]
      },
      "invites": {
        "data": [
          {
            "id": "5b4f337bff4304610483ba67"
          }
        ],
        "links": {
          "self": "/v2/contracts/5b4f337bff4304610483ba67/invites"
        }
      }
    }
  },
  "included": [
    {
      "id": "5b4f337bff4304610483ba67",
      "attributes": {
        "first_name": "John",
        "last_name": "Doe",
        "roles": [
          "admin"
        ],
        "email": "john.doe@gmail.com"
      },
      "relationships": {
        "user": {
          "data": {
            "id": "5b4f337bff4304610483ba67"
          },
          "links": {
            "self": "/v2/users/5b4f337bff4304610483ba67"
          }
        }
      }
    }
  ]
}