Skip to main content

create-ticket

dci create-ticket [body]

Creates a new support request

Pass the request body as name: value arguments or pipe JSON on stdin — see Command structure.

Examples

# Open a Google Cloud support request from a JSON file.
dci create-ticket < ticket.json
# ticket.json
{"ticket": {"subject": "BigQuery job stuck in PENDING",
"body": "Job bquxjob_1234 in project prod-analytics has been pending since 09:00 UTC.",
"platform": "google_cloud_platform", "product": "BigQuery", "severity": "normal"}}
# A short low-severity request about DoiT itself, written inline.
dci create-ticket ticket{subject: "Invoice question", body: "Which contract covers invoice INV-2026-08?", platform: doit, product: Billing, severity: low}
# Create the ticket and keep only its ID and console link, for scripts.
dci create-ticket --fields id,urlUI --output json < ticket.json
Add `requester` to the body only when calling as a service account; user callers must omit it — their verified email is the requester.

Request

Content-Type: application/json

FieldTypeRequiredDescription
ticketobjectyesPayload to create a support ticket via API.
ticket.bodystringyesThe body of the ticket (can include html formatting).
ticket.createdstringTicket creation time.
ticket.platformstringyesPlatform of the ticket. One of: "doit", "google_cloud_platform", "amazon_web_services", "microsoft_azure".
ticket.productstringyesTicket product details.
ticket.requesterstring (email)Human contact email used as the Zendesk ticket requester. Required when the caller is a service account. User callers must omit this field; their verified email remains the requester.
ticket.severitystringyesTicket severity. One of: "low", "normal", "high", "urgent".
ticket.subjectstringyesThe subject of the ticket.
Raw JSON schema
{
"type": "object",
"description": "Wrapper object for creating support tickets via the external API.",
"x-cloudflow-labels": {
"ticket": "Ticket details"
},
"properties": {
"ticket": {
"type": "object",
"description": "Payload to create a support ticket via API.",
"required": [
"body",
"platform",
"product",
"severity",
"subject"
],
"properties": {
"body": {
"type": "string",
"description": "The body of the ticket (can include html formatting).",
"x-cloudflow-format": "multiReference"
},
"created": {
"type": "string",
"description": "Ticket creation time."
},
"platform": {
"type": "string",
"description": "Platform of the ticket.",
"enum": [
"doit",
"google_cloud_platform",
"amazon_web_services",
"microsoft_azure"
]
},
"product": {
"type": "string",
"description": "Ticket product details."
},
"requester": {
"type": "string",
"format": "email",
"description": "Human contact email used as the Zendesk ticket requester. Required\nwhen the caller is a service account. User callers must omit this\nfield; their verified email remains the requester."
},
"severity": {
"type": "string",
"description": "Ticket severity.",
"enum": [
"low",
"normal",
"high",
"urgent"
],
"x-cloudflow-format": "noReference"
},
"subject": {
"type": "string",
"description": "The subject of the ticket."
}
}
}
},
"required": [
"ticket"
]
}

Output

Created - New support request created.

By default dci renders the result as a table. Use --output json to get the full structure described below — see Output formats.

FieldTypeDescription
createdinteger (int64)Ticket creation time.
idinteger (int64)Ticket ID.
platformstringTicket platform. One of: "doit", "google_cloud_platform", "amazon_web_services", "microsoft_azure".
productstringTicket product.
requesterstringEmail address of the requester.
severitystringSeverity of the ticket. One of: "low", "normal", "high", "urgent".
statusstringTicket status.
subjectstringTicket subject.
urlUIstringURL to access the ticket in DoiT console.
Raw JSON schema
{
"type": "object",
"description": "Response returned after creating a ticket.",
"properties": {
"created": {
"type": "integer",
"description": "Ticket creation time.",
"format": "int64"
},
"id": {
"type": "integer",
"description": "Ticket ID.",
"format": "int64"
},
"platform": {
"type": "string",
"description": "Ticket platform.",
"enum": [
"doit",
"google_cloud_platform",
"amazon_web_services",
"microsoft_azure"
]
},
"product": {
"type": "string",
"description": "Ticket product."
},
"requester": {
"type": "string",
"description": "Email address of the requester."
},
"severity": {
"type": "string",
"description": "Severity of the ticket.",
"enum": [
"low",
"normal",
"high",
"urgent"
]
},
"status": {
"type": "string",
"description": "Ticket status."
},
"subject": {
"type": "string",
"description": "Ticket subject."
},
"urlUI": {
"type": "string",
"description": "URL to access the ticket in DoiT console."
}
}
}

Errors

On failure, dci prints a single error message — with a hint when one is available — and exits with a typed code your scripts can branch on. See Errors and exit codes for the full contract.

HTTP status to exit code mapping
HTTP statusExit codeError codeMeaning
40030VALIDATION_ERRORThe arguments or request body were rejected. Review the command's flags and payload.
40110AUTHENTICATION_FAILEDNot signed in, or the API token is invalid. Run dci login or check DCI_API_KEY.
40311PERMISSION_DENIEDThe DoiT user or the active customer context does not have access.
40420RESOURCE_NOT_FOUNDThe requested resource does not exist. Check the identifier argument.

Aliases: id-of-tickets-post