//Create a Payload
vSms is Variant
vMessage is Variant
vMessage.sender = "Asterix"
vMessage.text = "Message via Api"
vMessage.pushtype = "alert"
vSms.message = vMessage
tabNumbers is array of strings = ["0600000000", "0600000001"]
tabGsm is array of Variants
FOR EACH sNumber OF tabNumbers
vGsm is Variant
vGsm.value = sNumber
tabGsm.Add(vGsm)
END
vRecipient is Variant
vRecipient.gsm = tabGsm
vSms.recipients = vRecipient
vPostData is Variant
vPostData.sms = vSms
//Request
sRequestUrl is string = "https://api.smsfactor.com/send"
sToken is string = "" //Your token created in your platform's profile https://my.smsfactor.com/developers/api-tokens
sHeader is string
sHeader = "Accept: application/json" + CR + "Authorization: Bearer " + sToken
IF HTTPRequest(sRequestUrl,"Windev", sHeader,VariantToJSON(vPostData), "application/json") = True THEN
Trace("requete OK, resultat :", HTMLToText(HTTPGetResult())) //API return value
ELSE
Error(ErrorInfo())
END