Skip to content

403 Error #26

@daniel-lucio

Description

@daniel-lucio

I have followed the example, put my own Key and my cellphone number as the destination. After turning the debug on, I always see a 403.

php74 test.php
[DEBUG] HTTP Request body BEGIN
[{"phone_number":"16138535080","message":"test1","device_id":1}]
END
[DEBUG] HTTP Response body BEGIN
{"status":"fail","message":"Could not process request","data":{"exception":"Access Denied."}}
END

  • About to connect() to smsgateway.me port 443 (#0)
  • Trying 142.93.107.113...
  • Connected to smsgateway.me (142.93.107.113) port 443 (#0)
  • Initializing NSS with certpath: sql:/etc/pki/nssdb
  • skipping SSL peer certificate verification
  • SSL connection using TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
  • Server certificate:
  •   subject: CN=smsgateway.me
    
  •   start date: Jul 15 20:09:08 2021 GMT
    
  •   expire date: Oct 13 20:09:06 2021 GMT
    
  •   common name: smsgateway.me
    
  •   issuer: CN=R3,O=Let's Encrypt,C=US
    

POST /api/v4/message/send HTTP/1.1
User-Agent: Swagger-Codegen/v0.0.1/php
Host: smsgateway.me
Accept: application/json
Content-Type: application/json
Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJhZG1pbiIsImlhdCI6MTYzMTAzNjgzNCwiZXhwIjo0MTAyNDQ0ODAwLCJ1aWQiOjgwMzY1LCJyb2xlcyI6WyJST0xFX1VTRVIiXX0.SzVDDkiKXchJLKQqWplDvUYRB3s-WiWu9KtLr8bJUJw
Content-Length: 64

  • upload completely sent off: 64 out of 64 bytes
    < HTTP/1.1 403 Forbidden
    < Date: Tue, 07 Sep 2021 17:48:37 GMT
    < Server: Apache/2.4.18 (Ubuntu)
    < Cache-Control: no-cache, private
    < Transfer-Encoding: chunked
    < Content-Type: application/json
    <
  • Connection #0 to host smsgateway.me left intact
    PHP Fatal error: Uncaught SMSGatewayMe\Client\ApiException: [403] Error connecting to the API (https://smsgateway.me/api/v4/message/send) in /var/www/clients/client0/web102/private/smsgateway/vendor/smsgatewayme/client/lib/ApiClient.php:247
    Stack trace:
    #0 /var/www/clients/client0/web102/private/smsgateway/vendor/smsgatewayme/client/lib/Api/MessageApi.php(525): SMSGatewayMe\Client\ApiClient->callApi()
    Erorr client-php.git #1 /var/www/clients/client0/web102/private/smsgateway/vendor/smsgatewayme/client/lib/Api/MessageApi.php(459): SMSGatewayMe\Client\Api\MessageApi->sendMessagesWithHttpInfo()
    Callback parameters #2 /var/www/clients/client0/web102/private/smsgateway/test.php(30): SMSGatewayMe\Client\Api\MessageApi->sendMessages()
    smsGateway.php????? #3 {main}
    thrown in /var/www/clients/client0/web102/private/smsgateway/vendor/smsgatewayme/client/lib/ApiClient.php on line 247

I have already changed my authkey for the sake of my own security.

What am I missing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions