import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: 'My API Key',
});
const response = await client.texml.secrets({ name: 'My Secret Name', value: 'My Secret Value' });
console.log(response.data);{
"data": {
"name": "My Secret Name",
"value": "*****"
}
}Create a TeXML secret which can be later used as a Dynamic Parameter for TeXML when using Mustache Templates in your TeXML. In your TeXML you will be able to use your secret name, and this name will be replaced by the actual secret value when processing the TeXML on Telnyx side. The secrets are not visible in any logs.
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: 'My API Key',
});
const response = await client.texml.secrets({ name: 'My Secret Name', value: 'My Secret Value' });
console.log(response.data);{
"data": {
"name": "My Secret Name",
"value": "*****"
}
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Create TeXML secret request object
Was this page helpful?