mailslurp.api.WebhookControllerApi

Load the API package

import 'package:mailslurp/api.dart';

All URIs are relative to https://api.mailslurp.com

MethodHTTP requestDescription
createWebhookPOST /inboxes/{inboxId}/webhooksAttach a WebHook URL to an inbox
deleteWebhookDELETE /inboxes/{inboxId}/webhooks/{webhookId}Delete and disable a Webhook for an Inbox
getAllWebhookResultsGET /webhooks/resultsGet results for all webhooks
getAllWebhooksGET /webhooks/paginatedList Webhooks Paginated
getInboxWebhooksPaginatedGET /inboxes/{inboxId}/webhooks/paginatedGet paginated webhooks for an Inbox
getJsonSchemaForWebhookPayloadPOST /webhooks/{webhookId}/schemaGet JSON Schema definition for webhook payload
getTestWebhookPayloadGET /webhooks/testGet test webhook payload example. Response content depends on eventName passed. Uses EMAIL_RECEIVED as default.
getTestWebhookPayloadEmailOpenedGET /webhooks/test/email-opened-payloadGet webhook test payload for email opened event
getTestWebhookPayloadEmailReadGET /webhooks/test/email-read-payloadGet webhook test payload for email opened event
getTestWebhookPayloadForWebhookPOST /webhooks/{webhookId}/exampleGet example payload for webhook
getTestWebhookPayloadNewAttachmentGET /webhooks/test/new-attachment-payloadGet webhook test payload for new attachment event
getTestWebhookPayloadNewContactGET /webhooks/test/new-contact-payloadGet webhook test payload for new contact event
getTestWebhookPayloadNewEmailGET /webhooks/test/new-email-payloadGet webhook test payload for new email event
getWebhookGET /webhooks/{webhookId}Get a webhook for an Inbox
getWebhookResultGET /webhooks/results/{webhookResultId}Get a webhook result for a webhook
getWebhookResultsGET /webhooks/{webhookId}/resultsGet a webhook results for a webhook
getWebhooksGET /inboxes/{inboxId}/webhooksGet all webhooks for an Inbox
redriveWebhookResultPOST /webhooks/results/{webhookResultId}/redriveGet a webhook result and try to resend the original webhook payload
sendTestDataPOST /webhooks/{webhookId}/testSend webhook test data

createWebhook

WebhookDto createWebhook(inboxId, webhookOptions)

Attach a WebHook URL to an inbox

Get notified whenever an inbox receives an email via a WebHook URL. An emailID will be posted to this URL every time an email is received for this inbox. The URL must be publicly reachable by the MailSlurp server. You can provide basicAuth values if you wish to secure this endpoint.

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final inboxId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | inboxId
final webhookOptions = CreateWebhookOptions(); // CreateWebhookOptions | webhookOptions

try { 
    final result = api_instance.createWebhook(inboxId, webhookOptions);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->createWebhook: $en');
}

Parameters

NameTypeDescriptionNotes
inboxIdStringinboxId
webhookOptionsCreateWebhookOptionswebhookOptions

Return type

WebhookDto

Authorization

API_KEY

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

deleteWebhook

deleteWebhook(inboxId, webhookId)

Delete and disable a Webhook for an Inbox

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final inboxId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | inboxId
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | webhookId

try { 
    api_instance.deleteWebhook(inboxId, webhookId);
} catch (e) {
    print('Exception when calling WebhookControllerApi->deleteWebhook: $en');
}

Parameters

NameTypeDescriptionNotes
inboxIdStringinboxId
webhookIdStringwebhookId

Return type

void (empty response body)

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getAllWebhookResults

PageWebhookResult getAllWebhookResults(before, page, searchFilter, since, size, sort)

Get results for all webhooks

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final before = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at before the given timestamp
final page = 56; // int | Optional page  in list pagination
final searchFilter = searchFilter_example; // String | Optional search filter
final since = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at after the given timestamp
final size = 56; // int | Optional page size in list pagination
final sort = sort_example; // String | Optional createdAt sort direction ASC or DESC

try { 
    final result = api_instance.getAllWebhookResults(before, page, searchFilter, since, size, sort);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getAllWebhookResults: $en');
}

Parameters

NameTypeDescriptionNotes
beforeDateTimeFilter by created at before the given timestamp[optional]
pageintOptional page in list pagination[optional] [default to 0]
searchFilterStringOptional search filter[optional]
sinceDateTimeFilter by created at after the given timestamp[optional]
sizeintOptional page size in list pagination[optional] [default to 20]
sortStringOptional createdAt sort direction ASC or DESC[optional] [default to ‘ASC’]

Return type

PageWebhookResult

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getAllWebhooks

PageWebhookProjection getAllWebhooks(before, page, searchFilter, since, size, sort)

List Webhooks Paginated

List webhooks in paginated form. Allows for page , page size, and sort direction.

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final before = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at before the given timestamp
final page = 56; // int | Optional page  in list pagination
final searchFilter = searchFilter_example; // String | Optional search filter
final since = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at after the given timestamp
final size = 56; // int | Optional page size for paginated result list.
final sort = sort_example; // String | Optional createdAt sort direction ASC or DESC

try { 
    final result = api_instance.getAllWebhooks(before, page, searchFilter, since, size, sort);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getAllWebhooks: $en');
}

Parameters

NameTypeDescriptionNotes
beforeDateTimeFilter by created at before the given timestamp[optional]
pageintOptional page in list pagination[optional] [default to 0]
searchFilterStringOptional search filter[optional]
sinceDateTimeFilter by created at after the given timestamp[optional]
sizeintOptional page size for paginated result list.[optional] [default to 20]
sortStringOptional createdAt sort direction ASC or DESC[optional] [default to ‘DESC’]

Return type

PageWebhookProjection

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getInboxWebhooksPaginated

PageWebhookProjection getInboxWebhooksPaginated(inboxId, before, page, searchFilter, since, size, sort)

Get paginated webhooks for an Inbox

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final inboxId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | inboxId
final before = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at before the given timestamp
final page = 56; // int | Optional page  in list pagination
final searchFilter = searchFilter_example; // String | Optional search filter
final since = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at after the given timestamp
final size = 56; // int | Optional page size in list pagination
final sort = sort_example; // String | Optional createdAt sort direction ASC or DESC

try { 
    final result = api_instance.getInboxWebhooksPaginated(inboxId, before, page, searchFilter, since, size, sort);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getInboxWebhooksPaginated: $en');
}

Parameters

NameTypeDescriptionNotes
inboxIdStringinboxId
beforeDateTimeFilter by created at before the given timestamp[optional]
pageintOptional page in list pagination[optional] [default to 0]
searchFilterStringOptional search filter[optional]
sinceDateTimeFilter by created at after the given timestamp[optional]
sizeintOptional page size in list pagination[optional] [default to 20]
sortStringOptional createdAt sort direction ASC or DESC[optional] [default to ‘ASC’]

Return type

PageWebhookProjection

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getJsonSchemaForWebhookPayload

JSONSchemaDto getJsonSchemaForWebhookPayload(webhookId)

Get JSON Schema definition for webhook payload

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | webhookId

try { 
    final result = api_instance.getJsonSchemaForWebhookPayload(webhookId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getJsonSchemaForWebhookPayload: $en');
}

Parameters

NameTypeDescriptionNotes
webhookIdStringwebhookId

Return type

JSONSchemaDto

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayload

AbstractWebhookPayload getTestWebhookPayload(eventName)

Get test webhook payload example. Response content depends on eventName passed. Uses EMAIL_RECEIVED as default.

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final eventName = eventName_example; // String | eventName

try { 
    final result = api_instance.getTestWebhookPayload(eventName);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayload: $en');
}

Parameters

NameTypeDescriptionNotes
eventNameStringeventName[optional]

Return type

AbstractWebhookPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadEmailOpened

WebhookEmailOpenedPayload getTestWebhookPayloadEmailOpened()

Get webhook test payload for email opened event

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();

try { 
    final result = api_instance.getTestWebhookPayloadEmailOpened();
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadEmailOpened: $en');
}

Parameters

This endpoint does not need any parameter.

Return type

WebhookEmailOpenedPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadEmailRead

WebhookEmailReadPayload getTestWebhookPayloadEmailRead()

Get webhook test payload for email opened event

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();

try { 
    final result = api_instance.getTestWebhookPayloadEmailRead();
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadEmailRead: $en');
}

Parameters

This endpoint does not need any parameter.

Return type

WebhookEmailReadPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadForWebhook

AbstractWebhookPayload getTestWebhookPayloadForWebhook(webhookId)

Get example payload for webhook

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | webhookId

try { 
    final result = api_instance.getTestWebhookPayloadForWebhook(webhookId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadForWebhook: $en');
}

Parameters

NameTypeDescriptionNotes
webhookIdStringwebhookId

Return type

AbstractWebhookPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadNewAttachment

WebhookNewAttachmentPayload getTestWebhookPayloadNewAttachment()

Get webhook test payload for new attachment event

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();

try { 
    final result = api_instance.getTestWebhookPayloadNewAttachment();
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadNewAttachment: $en');
}

Parameters

This endpoint does not need any parameter.

Return type

WebhookNewAttachmentPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadNewContact

WebhookNewContactPayload getTestWebhookPayloadNewContact()

Get webhook test payload for new contact event

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();

try { 
    final result = api_instance.getTestWebhookPayloadNewContact();
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadNewContact: $en');
}

Parameters

This endpoint does not need any parameter.

Return type

WebhookNewContactPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getTestWebhookPayloadNewEmail

WebhookNewEmailPayload getTestWebhookPayloadNewEmail()

Get webhook test payload for new email event

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();

try { 
    final result = api_instance.getTestWebhookPayloadNewEmail();
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getTestWebhookPayloadNewEmail: $en');
}

Parameters

This endpoint does not need any parameter.

Return type

WebhookNewEmailPayload

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getWebhook

WebhookDto getWebhook(webhookId)

Get a webhook for an Inbox

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | webhookId

try { 
    final result = api_instance.getWebhook(webhookId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getWebhook: $en');
}

Parameters

NameTypeDescriptionNotes
webhookIdStringwebhookId

Return type

WebhookDto

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getWebhookResult

WebhookResultDto getWebhookResult(webhookResultId)

Get a webhook result for a webhook

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookResultId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | Webhook Result ID

try { 
    final result = api_instance.getWebhookResult(webhookResultId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getWebhookResult: $en');
}

Parameters

NameTypeDescriptionNotes
webhookResultIdStringWebhook Result ID

Return type

WebhookResultDto

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getWebhookResults

PageWebhookResult getWebhookResults(webhookId, before, page, searchFilter, since, size, sort)

Get a webhook results for a webhook

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | ID of webhook to get results for
final before = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at before the given timestamp
final page = 56; // int | Optional page  in list pagination
final searchFilter = searchFilter_example; // String | Optional search filter
final since = 2013-10-20T19:20:30+01:00; // DateTime | Filter by created at after the given timestamp
final size = 56; // int | Optional page size in list pagination
final sort = sort_example; // String | Optional createdAt sort direction ASC or DESC

try { 
    final result = api_instance.getWebhookResults(webhookId, before, page, searchFilter, since, size, sort);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getWebhookResults: $en');
}

Parameters

NameTypeDescriptionNotes
webhookIdStringID of webhook to get results for
beforeDateTimeFilter by created at before the given timestamp[optional]
pageintOptional page in list pagination[optional] [default to 0]
searchFilterStringOptional search filter[optional]
sinceDateTimeFilter by created at after the given timestamp[optional]
sizeintOptional page size in list pagination[optional] [default to 20]
sortStringOptional createdAt sort direction ASC or DESC[optional] [default to ‘ASC’]

Return type

PageWebhookResult

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

getWebhooks

List getWebhooks(inboxId)

Get all webhooks for an Inbox

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final inboxId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | inboxId

try { 
    final result = api_instance.getWebhooks(inboxId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->getWebhooks: $en');
}

Parameters

NameTypeDescriptionNotes
inboxIdStringinboxId

Return type

List

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

redriveWebhookResult

WebhookRedriveResult redriveWebhookResult(webhookResultId)

Get a webhook result and try to resend the original webhook payload

Allows you to resend a webhook payload that was already sent. Webhooks that fail are retried automatically for 24 hours and then put in a dead letter queue. You can retry results manually using this method.

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookResultId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | Webhook Result ID

try { 
    final result = api_instance.redriveWebhookResult(webhookResultId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->redriveWebhookResult: $en');
}

Parameters

NameTypeDescriptionNotes
webhookResultIdStringWebhook Result ID

Return type

WebhookRedriveResult

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]

sendTestData

WebhookTestResult sendTestData(webhookId)

Send webhook test data

Example

import 'package:mailslurp/api.dart';
// TODO Configure API key authorization: API_KEY
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKey = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//defaultApiClient.getAuthentication<ApiKeyAuth>('API_KEY').apiKeyPrefix = 'Bearer';

final api_instance = WebhookControllerApi();
final webhookId = 38400000-8cf0-11bd-b23e-10b96e4ef00d; // String | webhookId

try { 
    final result = api_instance.sendTestData(webhookId);
    print(result);
} catch (e) {
    print('Exception when calling WebhookControllerApi->sendTestData: $en');
}

Parameters

NameTypeDescriptionNotes
webhookIdStringwebhookId

Return type

WebhookTestResult

Authorization

API_KEY

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to ]