Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
The official Docusign eSignature JAVA client is based on version 2.1 of the Docusign REST API and provides libraries for JAVA application integration. It is recommended that you use this version of the library for new development.
package com.docusign.esign.api;
import com.docusign.esign.client.ApiClient;
import com.docusign.esign.client.ApiException;
import com.docusign.esign.client.ApiResponse;
import com.docusign.esign.client.Configuration;
import com.docusign.esign.client.Pair;
import com.docusign.esign.model.*;
import jakarta.ws.rs.core.GenericType;
/** EmailArchiveApi class. */
public class EmailArchiveApi {
private ApiClient apiClient;
/** EmailArchiveApi. */
public EmailArchiveApi() {
this(Configuration.getDefaultApiClient());
}
/** EmailArchiveApi. */
public EmailArchiveApi(ApiClient apiClient) {
this.apiClient = apiClient;
}
/**
* getApiClient Method.
*
* @return ApiClient
*/
public ApiClient getApiClient() {
return apiClient;
}
/** setApiClient Method. */
public void setApiClient(ApiClient apiClient) {
this.apiClient = apiClient;
}
/**
* Creates a blind carbon copy email archive entry. This method creates a BCC email archive
* configuration for an account (adds a BCC email address to the account for archiving the emails
* that DocuSign generates). The only property that you must set in the request body is the BCC
* email address that you want to use. **Note:** An account can have up to five active and pending
* email archive addresses combined, but you must use this method to add them to the account one
* at a time. Each email address is considered a separate BCC email archive configuration.
*
* @param accountId The external account number (int) or account ID Guid. (required)
* @param bccEmailArchive (optional)
* @return BccEmailArchive
* @throws ApiException if fails to make API call
*/
public BccEmailArchive createBCCEmailArchive(String accountId, BccEmailArchive bccEmailArchive)
throws ApiException {
ApiResponse localVarResponse =
createBCCEmailArchiveWithHttpInfo(accountId, bccEmailArchive);
return localVarResponse.getData();
}
/**
* Creates a blind carbon copy email archive entry This method creates a BCC email archive
* configuration for an account (adds a BCC email address to the account for archiving the emails
* that DocuSign generates). The only property that you must set in the request body is the BCC
* email address that you want to use. **Note:** An account can have up to five active and pending
* email archive addresses combined, but you must use this method to add them to the account one
* at a time. Each email address is considered a separate BCC email archive configuration.
*
* @param accountId The external account number (int) or account ID Guid. (required)
* @param bccEmailArchive (optional)
* @return BccEmailArchive
* @throws ApiException if fails to make API call
*/
public ApiResponse createBCCEmailArchiveWithHttpInfo(
String accountId, BccEmailArchive bccEmailArchive) throws ApiException {
Object localVarPostBody = bccEmailArchive;
// verify the required parameter 'accountId' is set
if (accountId == null) {
throw new ApiException(
400, "Missing the required parameter 'accountId' when calling createBCCEmailArchive");
}
// create path and map variables
String localVarPath =
"/v2.1/accounts/{accountId}/settings/bcc_email_archives"
.replaceAll("\\{" + "accountId" + "\\}", apiClient.escapeString(accountId.toString()));
// query params
java.util.List localVarQueryParams = new java.util.ArrayList();
java.util.List localVarCollectionQueryParams = new java.util.ArrayList();
java.util.Map localVarHeaderParams = new java.util.HashMap();
java.util.Map localVarFormParams = new java.util.HashMap();
final String[] localVarAccepts = {"application/json"};
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = {};
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] {"docusignAccessCode"};
GenericType localVarReturnType = new GenericType() {};
BccEmailArchive localVarResponse =
apiClient.invokeAPI(
localVarPath,
"POST",
localVarQueryParams,
localVarCollectionQueryParams,
localVarPostBody,
localVarHeaderParams,
localVarFormParams,
localVarAccept,
localVarContentType,
localVarAuthNames,
localVarReturnType);
return new ApiResponse(
apiClient.getStatusCode(), apiClient.getResponseHeaders(), localVarResponse);
}
/**
* Delete a blind carbon copy email archive for an account.. This method deletes a BCC email
* archive configuration from an account. When you use this method, the status of the BCC email
* archive configuration switches to `closed` and the BCC email address is no longer
* used to archive DocuSign-generated email messages.
*
* @param accountId The external account number (int) or account ID Guid. (required)
* @param bccEmailArchiveId (required)
* @throws ApiException if fails to make API call
*/
public void deleteBCCEmailArchive(String accountId, String bccEmailArchiveId)
throws ApiException {
deleteBCCEmailArchiveWithHttpInfo(accountId, bccEmailArchiveId);
}
/**
* Delete a blind carbon copy email archive for an account. This method deletes a BCC email
* archive configuration from an account. When you use this method, the status of the BCC email
* archive configuration switches to `closed` and the BCC email address is no longer
* used to archive DocuSign-generated email messages.
*
* @param accountId The external account number (int) or account ID Guid. (required)
* @param bccEmailArchiveId (required)
* @throws ApiException if fails to make API call
*/
public ApiResponse