Stellar PHP SDK API Documentation

SEP08PostTransactionPending extends SEP08PostTransactionResponse

Response indicating the approval decision is delayed and should be retried.

This response means the issuer could not determine whether to approve the transaction at the time of receiving it. The wallet should wait for the specified timeout period and then resubmit the same transaction.

Common reasons for pending responses:

  • Manual review required by compliance team
  • External service dependency (KYC provider, sanctions screening)
  • Rate limiting or temporary service overload
  • Awaiting additional information from other systems

The timeout field indicates how long to wait before resubmitting. If timeout is 0 or not provided, the wallet should implement its own retry strategy (e.g., exponential backoff starting at 5 seconds).

HTTP Status Code: 200

Tags
see
https://github.com/stellar/stellar-protocol/blob/v1.7.4/ecosystem/sep-0008.md#pending

SEP-0008 v1.7.4

Table of Contents

Properties

$message  : string|null
$timeout  : int
Number of milliseconds to wait before resubmitting the transaction.

Methods

__construct()  : mixed
Constructor.
fromJson()  : SEP08PostTransactionResponse
Factory method to construct a transaction response object from JSON data.

Properties

$message

public string|null $message = null

(optional) A human-readable string containing information to pass on to the user.

$timeout

Number of milliseconds to wait before resubmitting the transaction.

public int $timeout = 0

A value of 0 indicates the wait time cannot be determined. Wallets should implement their own retry strategy (e.g., exponential backoff starting at 5 seconds).

Per SEP-0008, the server should provide this value to prevent excessive polling.

Default: 0 (wait time unknown)

Methods

__construct()

Constructor.

public __construct([int|null $timeout = null ][, string|null $message = null ]) : mixed
Parameters
$timeout : int|null = null

Number of milliseconds to wait before submitting the same transaction again.

$message : string|null = null

(optional) A human-readable string containing information to pass on to the user.

fromJson()

Factory method to construct a transaction response object from JSON data.

public static fromJson(array<string|int, mixed> $json) : SEP08PostTransactionResponse

Parses the JSON response from an approval server and instantiates the appropriate concrete response class based on the 'status' field value.

Status Mapping:

  • "success" -> SEP08PostTransactionSuccess
  • "revised" -> SEP08PostTransactionRevised
  • "pending" -> SEP08PostTransactionPending
  • "action_required" -> SEP08PostTransactionActionRequired
  • "rejected" -> SEP08PostTransactionRejected
Parameters
$json : array<string|int, mixed>

Decoded JSON response from approval server

Tags
throws
SEP08InvalidPostTransactionResponse

If status field is missing, unknown, or required fields for the given status are missing

Return values
SEP08PostTransactionResponse

Concrete subclass instance based on status field


        
On this page

Search results