Skip to main content

list-contracts

dci list-contracts customerID

Lists the contracts held by the specified customer. Callable by a T1/T2 PartnerOps principal for its own tenant or any descendant tenant. Read access requires contractsReadOnly, contractsViewer, or a write-capable role (without contractsReadOnly). User API tokens must include the matching permission in their scope.

Responses

200 (application/json)

OK - The request succeeded.

{
"type": "array",
"items": {
"type": "object",
"description": "External view of a contract. DoiT-internal fields are not exposed.",
"properties": {
"id": {
"type": "string",
"description": "The unique identifier of the contract."
},
"customerId": {
"type": "string",
"description": "The customer (tenant) that holds the contract."
},
"type": {
"type": "string",
"description": "The immutable contract type."
},
"status": {
"type": "string",
"description": "The contract status.",
"enum": [
"draft",
"scheduled",
"active",
"cancelled",
"expired",
"superseded"
]
},
"name": {
"type": "string",
"description": "The contract name."
},
"startDate": {
"type": "string",
"format": "date-time",
"nullable": true,
"description": "The contract start date."
},
"endDate": {
"type": "string",
"format": "date-time",
"nullable": true,
"description": "The contract end date."
},
"renewalPolicy": {
"type": "string",
"description": "The renewal policy.",
"enum": [
"auto",
"manual",
"fixed"
]
},
"currentVersionNumber": {
"type": "integer",
"nullable": true,
"description": "The current version number of the contract."
},
"timeCreated": {
"type": "string",
"format": "date-time",
"description": "When the contract was created."
}
}
}
}

401 (application/json)

Unauthorized - Invalid API key.

{
"type": "object",
"description": "Standard error response structure.",
"properties": {
"error": {
"type": "string",
"description": "Detailed error message."
}
}
}

403 (application/json)

Forbidden - The client is not authorized to perform the request.

{
"type": "object",
"description": "Standard error response structure.",
"properties": {
"error": {
"type": "string",
"description": "Detailed error message."
}
}
}

Aliases: list-contracts, listcontracts