Stellar PHP SDK API Documentation

SubmitContractChallengeUnknownResponseException extends Exception

Exception thrown when submitting signed authorization entries returns an unexpected response.

This exception is thrown when the POST request to the WEB_AUTH_FOR_CONTRACTS_ENDPOINT returns an HTTP status code other than 200, 400, or 504. This indicates an unexpected server response that doesn't conform to the SEP-45 specification.

Common scenarios:

  • 401 Unauthorized: Server requires additional authentication
  • 403 Forbidden: Client not allowed to use the service
  • 404 Not Found: Endpoint not available
  • 429 Too Many Requests: Rate limit exceeded
  • 500 Internal Server Error: Server-side error
  • 502 Bad Gateway: Proxy or gateway error
  • 503 Service Unavailable: Server temporarily unavailable

The exception includes both the HTTP status code and the raw response body for debugging and error reporting purposes.

Tags
see
https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0045.md

SEP-45 Token Endpoint

Table of Contents

Methods

__construct()  : mixed
Creates a new unknown response exception.
getHttpStatusCode()  : int
Returns the HTTP status code from the response.
getResponseBody()  : string
Returns the raw response body from the server.

Methods

__construct()

Creates a new unknown response exception.

public __construct(string $responseBody, int $httpStatusCode) : mixed
Parameters
$responseBody : string

the raw response body from the server

$httpStatusCode : int

the HTTP status code from the response


        
On this page

Search results