InboxForwarderControllerApi

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

MethodHTTP requestDescription
createNewInboxForwarderPOST /forwardersCreate an inbox forwarder
deleteInboxForwarderDELETE /forwarders/{id}Delete an inbox forwarder
deleteInboxForwardersDELETE /forwardersDelete inbox forwarders
getInboxForwarderGET /forwarders/{id}Get an inbox forwarder
getInboxForwardersGET /forwardersList inbox forwarders
testInboxForwarderPOST /forwarders/{id}/testTest an inbox forwarder
testInboxForwardersForInboxPUT /forwardersTest inbox forwarders for inbox
testNewInboxForwarderPATCH /forwardersTest new inbox forwarder

createNewInboxForwarder

InboxForwarderDto createNewInboxForwarder(createInboxForwarderOptions, inboxId)

Create an inbox forwarder

Create a new inbox rule for forwarding, blocking, and allowing emails when sending and receiving

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    CreateInboxForwarderOptions createInboxForwarderOptions = new CreateInboxForwarderOptions(); // CreateInboxForwarderOptions | createInboxForwarderOptions
    UUID inboxId = new UUID(); // UUID | Inbox id to attach forwarder to
    try {
      InboxForwarderDto result = apiInstance.createNewInboxForwarder(createInboxForwarderOptions, inboxId);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#createNewInboxForwarder");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
createInboxForwarderOptionsCreateInboxForwarderOptionscreateInboxForwarderOptions
inboxIdUUIDInbox id to attach forwarder to[optional]

Return type

InboxForwarderDto

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
201Created-
401Unauthorized-
403Forbidden-
404Not Found-

deleteInboxForwarder

deleteInboxForwarder(id)

Delete an inbox forwarder

Delete inbox forwarder

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID id = new UUID(); // UUID | ID of inbox forwarder
    try {
      apiInstance.deleteInboxForwarder(id);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#deleteInboxForwarder");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
idUUIDID of inbox forwarder

Return type

null (empty response body)

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
204No Content-
401Unauthorized-
403Forbidden-

deleteInboxForwarders

deleteInboxForwarders(inboxId)

Delete inbox forwarders

Delete inbox forwarders. Accepts optional inboxId filter.

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID inboxId = new UUID(); // UUID | Optional inbox id to attach forwarder to
    try {
      apiInstance.deleteInboxForwarders(inboxId);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#deleteInboxForwarders");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
inboxIdUUIDOptional inbox id to attach forwarder to[optional]

Return type

null (empty response body)

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
204No Content-
401Unauthorized-
403Forbidden-

getInboxForwarder

InboxForwarderDto getInboxForwarder(id)

Get an inbox forwarder

Get inbox ruleset

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID id = new UUID(); // UUID | ID of inbox forwarder
    try {
      InboxForwarderDto result = apiInstance.getInboxForwarder(id);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#getInboxForwarder");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
idUUIDID of inbox forwarder

Return type

InboxForwarderDto

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
401Unauthorized-
403Forbidden-
404Not Found-

getInboxForwarders

PageInboxForwarderDto getInboxForwarders(inboxId, page, searchFilter, size, sort)

List inbox forwarders

List all forwarders attached to an inbox

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID inboxId = new UUID(); // UUID | Optional inbox id to get forwarders from
    Integer page = 0; // Integer | Optional page  in inbox forwarder list pagination
    String searchFilter = "searchFilter_example"; // String | Optional search filter
    Integer size = 20; // Integer | Optional page size in inbox forwarder list pagination
    String sort = "ASC"; // String | Optional createdAt sort direction ASC or DESC
    try {
      PageInboxForwarderDto result = apiInstance.getInboxForwarders(inboxId, page, searchFilter, size, sort);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#getInboxForwarders");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
inboxIdUUIDOptional inbox id to get forwarders from[optional]
pageIntegerOptional page in inbox forwarder list pagination[optional] [default to 0]
searchFilterStringOptional search filter[optional]
sizeIntegerOptional page size in inbox forwarder list pagination[optional] [default to 20]
sortStringOptional createdAt sort direction ASC or DESC[optional] [default to ASC] [enum: ASC, DESC]

Return type

PageInboxForwarderDto

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
401Unauthorized-
403Forbidden-
404Not Found-

testInboxForwarder

InboxForwarderTestResult testInboxForwarder(id, inboxForwarderTestOptions)

Test an inbox forwarder

Test an inbox forwarder

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID id = new UUID(); // UUID | ID of inbox forwarder
    InboxForwarderTestOptions inboxForwarderTestOptions = new InboxForwarderTestOptions(); // InboxForwarderTestOptions | inboxForwarderTestOptions
    try {
      InboxForwarderTestResult result = apiInstance.testInboxForwarder(id, inboxForwarderTestOptions);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#testInboxForwarder");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
idUUIDID of inbox forwarder
inboxForwarderTestOptionsInboxForwarderTestOptionsinboxForwarderTestOptions

Return type

InboxForwarderTestResult

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
201Created-
401Unauthorized-
403Forbidden-
404Not Found-

testInboxForwardersForInbox

InboxForwarderTestResult testInboxForwardersForInbox(inboxId, inboxForwarderTestOptions)

Test inbox forwarders for inbox

Test inbox forwarders for inbox

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    UUID inboxId = new UUID(); // UUID | ID of inbox
    InboxForwarderTestOptions inboxForwarderTestOptions = new InboxForwarderTestOptions(); // InboxForwarderTestOptions | inboxForwarderTestOptions
    try {
      InboxForwarderTestResult result = apiInstance.testInboxForwardersForInbox(inboxId, inboxForwarderTestOptions);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#testInboxForwardersForInbox");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
inboxIdUUIDID of inbox
inboxForwarderTestOptionsInboxForwarderTestOptionsinboxForwarderTestOptions

Return type

InboxForwarderTestResult

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
201Created-
401Unauthorized-
403Forbidden-
404Not Found-

testNewInboxForwarder

InboxForwarderTestResult testNewInboxForwarder(testNewInboxForwarderOptions)

Test new inbox forwarder

Test new inbox forwarder

Example

// Import classes:
import com.mailslurp.clients.ApiClient;
import com.mailslurp.clients.ApiException;
import com.mailslurp.clients.Configuration;
import com.mailslurp.clients.auth.*;
import com.mailslurp.clients.models.*;
import com.mailslurp.apis.InboxForwarderControllerApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://api.mailslurp.com");
    
    // Configure API key authorization: API_KEY
    ApiKeyAuth API_KEY = (ApiKeyAuth) defaultClient.getAuthentication("API_KEY");
    API_KEY.setApiKey("YOUR API KEY");
    // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    //API_KEY.setApiKeyPrefix("Token");

    InboxForwarderControllerApi apiInstance = new InboxForwarderControllerApi(defaultClient);
    TestNewInboxForwarderOptions testNewInboxForwarderOptions = new TestNewInboxForwarderOptions(); // TestNewInboxForwarderOptions | testNewInboxForwarderOptions
    try {
      InboxForwarderTestResult result = apiInstance.testNewInboxForwarder(testNewInboxForwarderOptions);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling InboxForwarderControllerApi#testNewInboxForwarder");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Parameters

NameTypeDescriptionNotes
testNewInboxForwarderOptionsTestNewInboxForwarderOptionstestNewInboxForwarderOptions

Return type

InboxForwarderTestResult

Authorization

API_KEY

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200OK-
204No Content-
401Unauthorized-
403Forbidden-