getSingleFromSubscriptionAndEvent static method
Future<PcoWebhooksDelivery?>
getSingleFromSubscriptionAndEvent(
- String subscriptionId,
- String eventId,
- String id, {
- PcoWebhooksDeliveryQuery? query,
Will get a single PcoWebhooksDelivery
object
using a path like this: /webhooks/v2/subscriptions/$subscriptionId/events/$eventId/deliveries/[id]
Additional options may be specified by using the query
argument, but some
query options are also available as boolean flags in this function call too.
Implementation
static Future<PcoWebhooksDelivery?> getSingleFromSubscriptionAndEvent(
String subscriptionId,
String eventId,
String id, {
PcoWebhooksDeliveryQuery? query,
}) async {
query ??= PcoWebhooksDeliveryQuery();
var url =
'/webhooks/v2/subscriptions/$subscriptionId/events/$eventId/deliveries/$id';
var retval = await PcoCollection.fromApiCall<PcoWebhooksDelivery>(url,
query: query, apiVersion: kApiVersion);
return retval.items.isEmpty ? null : retval.items.first;
}