Getting up on Twilio

philip.tulett at pdq-networks.com philip.tulett at pdq-networks.com
Mon Mar 6 17:13:57 UTC 2023


Hi Das, 

I should add that iHeaderName and iHeadervalue are both character variables, and obviously iHeaderList is a list variable.
 
Kind regards
Phil
-----Original Message-----
From: omnisdev-en <omnisdev-en-bounces at lists.omnis-dev.com> On Behalf Of philip.tulett at pdq-networks.com
Sent: Monday, March 6, 2023 5:11 PM
To: 'OmnisDev List - English' <omnisdev-en at lists.omnis-dev.com>
Subject: RE: Getting up on Twilio

Hi Das,

I use the following code to create the header list...
Do iHeadersList.$define(iHeaderName,iHeaderValue)
Do iHeadersList.$add("content-type","application/json")

In your case, the iHeadersList.$add would be something like:- Do iHeadersList.$add("-u your_account_sid"," your_auth_token")


Kind regards
Phil

-----Original Message-----
From: omnisdev-en <omnisdev-en-bounces at lists.omnis-dev.com> On Behalf Of Das Goravani
Sent: Monday, March 6, 2023 5:01 PM
To: OmnisDev List - English <omnisdev-en at lists.omnis-dev.com>
Subject: Re: Getting up on Twilio


HdrList is an optional parameter. It is an Omnis list with two character columns.. The list contains additional headers to add to the headers of the HTTP POST request. Note that the header name excludes the ‘:’, which HTTPPost inserts automatically when it formats the header.

How can I use the above to insert this:

-u your_account_sid:your_auth_token

I have the account SID string and token string. I just don’t know how to put this data into the HTTP Post command. 

I think that the header list described from Omnis manual above will insert my account SID and token with the : in-between them, I just don’t know how to get the -u in front of it. 


_____________________________________________________________
Manage your list subscriptions at https://lists.omnis-dev.com Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com 

_____________________________________________________________
Manage your list subscriptions at https://lists.omnis-dev.com Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com 



More information about the omnisdev-en mailing list