SDK reference · Python SDK

prov.authorize.calls.relay_code

prov.authorize.calls.relay_code in Python SDK. The last resort: a code and a short address the caller relays to its person.

Signature

prov.authorize.calls.relay_code(check_id: str) -> Any

Parameters

check_idstrRequired

Request fields

idstringpathRequired
The check's ID (ccx_).

Returns

Any The code and the address.

HTTP operation

POST /v1/authorize/call_checks/{id}/relay_codes: Issue a relayed code

Errors

Example

const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/authorize/call_checks`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json" },
  body: JSON.stringify({ "from": "+14155550178", "to": "+14155550123", "code": "123456" }),
})).json();
const checkId = step1.id;
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/authorize/call_checks/${checkId}/relay_codes`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5" },
})).json();

Was this page helpful? Send us feedback

LLM? Read llms.txt.