cURL
curl -X GET "$EXSITED_BASE_URL/api/v4/booking/BOOKING_ID/payment_methods" \
-H "Authorization: Bearer $ACCESS_TOKEN"from exsited import build_client
client = build_client()
response = client.bookings.get_booking_payment_methods("BOOKING_ID")
print(response.data)
import {buildClient} from 'exsited';
const client = await buildClient();
const response = await client.bookings.getBookingPaymentMethods('BOOKING_ID');
console.log(response.data);
use Exsited\Client\ClientRegistry;
$client = ClientRegistry::buildClient();
$response = $client->bookings->getBookingPaymentMethods('BOOKING_ID');
print_r($response->data);
import com.exsited.client.ApiResponse;
import com.exsited.client.ClientRegistry;
import com.exsited.client.ExsitedClient;
import com.exsited.resources.bookings.bookings_dto.BookingsDto.BookingPaymentMethods;
ExsitedClient client = ClientRegistry.buildClient();
ApiResponse<BookingPaymentMethods> response = client.bookings().getBookingPaymentMethods("BOOKING_ID");
System.out.println(response.getMap());
using Exsited.Client;
await using var client = ExsitedClient.BuildClient();
var response = await client.Bookings.GetBookingPaymentMethodsAsync("BOOKING_ID");
Console.WriteLine(response.Json);
import 'package:exsited/exsited.dart';
final client = buildClient();
final response = await client.bookings.getBookingPaymentMethods('BOOKING_ID');
print(response.map);
import (
"context"
"fmt"
"log"
exsited "github.com/exsited/exsited-sdk-go/v4"
)
client, err := exsited.BuildClient(nil)
if err != nil {
log.Fatal(err)
}
defer client.Close()
response, err := client.Bookings().GetBookingPaymentMethods(context.Background(), "BOOKING_ID", nil, nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(response.Map)
{
"order": {
"payment_methods": [
{
"created_by": "<string>",
"created_on": "<string>",
"default": true,
"id": "<string>",
"last_updated_by": "<string>",
"last_updated_on": "<string>",
"last_used_at": "<string>",
"object": "<string>",
"payment_count": 123,
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"processor_type": "<string>",
"reference": "<string>",
"restricted_to_orders": true,
"specified_order_ids": "<string>",
"status": "<string>",
"version": 123
}
]
}
}{
"object": "<string>",
"request_id": "<string>",
"status": 123,
"code": "<string>",
"message": "<string>",
"doc_url": "<string>",
"errors": [
{
"field": "<string>",
"code": "<string>",
"message": "<string>",
"doc_url": "<string>"
}
]
}Bookings
List a booking's payment methods
Lists the payment methods bound to a booking.
GET
/
booking
/
{booking_id}
/
payment_methods
cURL
curl -X GET "$EXSITED_BASE_URL/api/v4/booking/BOOKING_ID/payment_methods" \
-H "Authorization: Bearer $ACCESS_TOKEN"from exsited import build_client
client = build_client()
response = client.bookings.get_booking_payment_methods("BOOKING_ID")
print(response.data)
import {buildClient} from 'exsited';
const client = await buildClient();
const response = await client.bookings.getBookingPaymentMethods('BOOKING_ID');
console.log(response.data);
use Exsited\Client\ClientRegistry;
$client = ClientRegistry::buildClient();
$response = $client->bookings->getBookingPaymentMethods('BOOKING_ID');
print_r($response->data);
import com.exsited.client.ApiResponse;
import com.exsited.client.ClientRegistry;
import com.exsited.client.ExsitedClient;
import com.exsited.resources.bookings.bookings_dto.BookingsDto.BookingPaymentMethods;
ExsitedClient client = ClientRegistry.buildClient();
ApiResponse<BookingPaymentMethods> response = client.bookings().getBookingPaymentMethods("BOOKING_ID");
System.out.println(response.getMap());
using Exsited.Client;
await using var client = ExsitedClient.BuildClient();
var response = await client.Bookings.GetBookingPaymentMethodsAsync("BOOKING_ID");
Console.WriteLine(response.Json);
import 'package:exsited/exsited.dart';
final client = buildClient();
final response = await client.bookings.getBookingPaymentMethods('BOOKING_ID');
print(response.map);
import (
"context"
"fmt"
"log"
exsited "github.com/exsited/exsited-sdk-go/v4"
)
client, err := exsited.BuildClient(nil)
if err != nil {
log.Fatal(err)
}
defer client.Close()
response, err := client.Bookings().GetBookingPaymentMethods(context.Background(), "BOOKING_ID", nil, nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(response.Map)
{
"order": {
"payment_methods": [
{
"created_by": "<string>",
"created_on": "<string>",
"default": true,
"id": "<string>",
"last_updated_by": "<string>",
"last_updated_on": "<string>",
"last_used_at": "<string>",
"object": "<string>",
"payment_count": 123,
"processor": {
"object": "<string>",
"id": "<string>",
"name": "<string>",
"href": "<string>"
},
"processor_type": "<string>",
"reference": "<string>",
"restricted_to_orders": true,
"specified_order_ids": "<string>",
"status": "<string>",
"version": 123
}
]
}
}{
"object": "<string>",
"request_id": "<string>",
"status": 123,
"code": "<string>",
"message": "<string>",
"doc_url": "<string>",
"errors": [
{
"field": "<string>",
"code": "<string>",
"message": "<string>",
"doc_url": "<string>"
}
]
}Returns the account payment methods restricted to this booking, under
order.payment_methods.
The SDK samples get their client from credentials your app registers once when it starts, as shown in Authentication. To try the call here, click Try it, set
host to your Exsited API host name and paste an access token from Get an access token.Authorizations
An access token from POST /api/v4/oauth2/token. The SDKs get and renew it for you.
Path Parameters
The booking's id. Any order's id works here, whatever the order's type.
Response
The payment methods, under order.payment_methods.
Show child attributes
Show child attributes