Get Line Request
Lines & Leads
Get Line Request
Fetch the current status of a line request. REST endpoint in the Tuco AI iMessage API — bearer-token auth, JSON request/response, full schema and code examples.
GET
Get Line Request
Use this endpoint to poll a specific line request after creation. It is the source of truth for whether the request is still waiting for payment, already provisioning, active, failed, or canceled.
When To Use This Endpoint
Call this endpoint any time your integration wants to answer one of these questions:- Did the user already pay?
- Has provisioning started yet?
- Is the line active?
- Was the request canceled or did it fail?
POST /api/line-requests.
Authentication
Pass your workspace API key as a Bearer token, or use a Clerk session token.Path parameter
Required. The line request id returned by
POST /api/line-requests.Example
Success (200 OK)
Status behavior
status | Meaning |
|---|---|
awaiting_payment | Invoice is still unpaid |
provisioning | Payment is complete or not required, and Tuco is provisioning the line |
active | Line is ready to use |
failed | Provisioning did not succeed |
canceled | The pending request was canceled |
awaiting_payment request against the latest subscription state while reading this endpoint.
Practical meaning of each status
awaiting_paymentThe request exists, but the invoice is still unpaid or billing has not been reconciled yet.provisioningPayment is done or was never needed, and Tuco is now setting the line up.activeThe line is ready to use in normal message flows.failedProvisioning did not complete. At that point the request needs review or a retry path outside this endpoint.canceledThe pending request was intentionally canceled before completion.
Typical polling behavior
Most clients poll after:- creating a paid request
- showing the hosted invoice to the user
- waiting for the request to move from
awaiting_paymenttoprovisioning
active.
Error responses
| Status | When | Body |
|---|---|---|
400 | Invalid line request id | { "error": "Invalid line request id" } |
401 | Missing or invalid API key / session | { "error": "Unauthorized" } |
404 | Request not found in your workspace | { "error": "Line request not found" } |