@@ -760,6 +760,143 @@ public okhttp3.Call automationShowAsync(String accountId, String id, String xPhr
760760 localVarApiClient .executeAsync (localVarCall , localVarReturnType , _callback );
761761 return localVarCall ;
762762 }
763+ /**
764+ * Build call for automationTrigger
765+ * @param accountId Account ID (required)
766+ * @param id ID (required)
767+ * @param xPhraseAppOTP Two-Factor-Authentication token (optional) (optional)
768+ * @param _callback Callback for upload/download progress
769+ * @return Call to execute
770+ * @throws ApiException If fail to serialize the request body object
771+ * @http.response.details
772+ <table summary="Response Details" border="1">
773+ <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
774+ <tr><td> 204 </td><td> The resource was deleted successfully. </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
775+ <tr><td> 400 </td><td> Bad request </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
776+ <tr><td> 404 </td><td> Not Found </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
777+ <tr><td> 429 </td><td> Rate Limiting </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
778+ </table>
779+ */
780+ public okhttp3 .Call automationTriggerCall (String accountId , String id , String xPhraseAppOTP , final ApiCallback _callback ) throws ApiException {
781+ Object localVarPostBody = null ;
782+
783+ // create path and map variables
784+ String localVarPath = "/accounts/{account_id}/automations/{automation_id}/trigger"
785+ .replaceAll ("\\ {" + "account_id" + "\\ }" , localVarApiClient .escapeString (accountId .toString ()))
786+ .replaceAll ("\\ {" + "id" + "\\ }" , localVarApiClient .escapeString (id .toString ()));
787+
788+ List <Pair > localVarQueryParams = new ArrayList <Pair >();
789+ List <Pair > localVarCollectionQueryParams = new ArrayList <Pair >();
790+ Map <String , String > localVarHeaderParams = new HashMap <String , String >();
791+ if (xPhraseAppOTP != null ) {
792+ localVarHeaderParams .put ("X-PhraseApp-OTP" , localVarApiClient .parameterToString (xPhraseAppOTP ));
793+ }
794+
795+ Map <String , String > localVarCookieParams = new HashMap <String , String >();
796+ Map <String , Object > localVarFormParams = new HashMap <String , Object >();
797+ final String [] localVarAccepts = {
798+
799+ };
800+ final String localVarAccept = localVarApiClient .selectHeaderAccept (localVarAccepts );
801+ if (localVarAccept != null ) {
802+ localVarHeaderParams .put ("Accept" , localVarAccept );
803+ }
804+
805+ final String [] localVarContentTypes = {
806+
807+ };
808+ final String localVarContentType = localVarApiClient .selectHeaderContentType (localVarContentTypes );
809+ localVarHeaderParams .put ("Content-Type" , localVarContentType );
810+
811+ String [] localVarAuthNames = new String [] { "Basic" , "Token" };
812+ return localVarApiClient .buildCall (localVarPath , "POST" , localVarQueryParams , localVarCollectionQueryParams , localVarPostBody , localVarHeaderParams , localVarCookieParams , localVarFormParams , localVarAuthNames , _callback );
813+ }
814+
815+ @ SuppressWarnings ("rawtypes" )
816+ private okhttp3 .Call automationTriggerValidateBeforeCall (String accountId , String id , String xPhraseAppOTP , final ApiCallback _callback ) throws ApiException {
817+
818+ // verify the required parameter 'accountId' is set
819+ if (accountId == null ) {
820+ throw new ApiException ("Missing the required parameter 'accountId' when calling automationTrigger(Async)" );
821+ }
822+
823+ // verify the required parameter 'id' is set
824+ if (id == null ) {
825+ throw new ApiException ("Missing the required parameter 'id' when calling automationTrigger(Async)" );
826+ }
827+
828+
829+ okhttp3 .Call localVarCall = automationTriggerCall (accountId , id , xPhraseAppOTP , _callback );
830+ return localVarCall ;
831+
832+ }
833+
834+ /**
835+ * Trigger an automation
836+ * Trigger an automation.
837+ * @param accountId Account ID (required)
838+ * @param id ID (required)
839+ * @param xPhraseAppOTP Two-Factor-Authentication token (optional) (optional)
840+ * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
841+ * @http.response.details
842+ <table summary="Response Details" border="1">
843+ <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
844+ <tr><td> 204 </td><td> The resource was deleted successfully. </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
845+ <tr><td> 400 </td><td> Bad request </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
846+ <tr><td> 404 </td><td> Not Found </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
847+ <tr><td> 429 </td><td> Rate Limiting </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
848+ </table>
849+ */
850+ public void automationTrigger (String accountId , String id , String xPhraseAppOTP ) throws ApiException {
851+ automationTriggerWithHttpInfo (accountId , id , xPhraseAppOTP );
852+ }
853+
854+ /**
855+ * Trigger an automation
856+ * Trigger an automation.
857+ * @param accountId Account ID (required)
858+ * @param id ID (required)
859+ * @param xPhraseAppOTP Two-Factor-Authentication token (optional) (optional)
860+ * @return ApiResponse<Void>
861+ * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
862+ * @http.response.details
863+ <table summary="Response Details" border="1">
864+ <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
865+ <tr><td> 204 </td><td> The resource was deleted successfully. </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
866+ <tr><td> 400 </td><td> Bad request </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
867+ <tr><td> 404 </td><td> Not Found </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
868+ <tr><td> 429 </td><td> Rate Limiting </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
869+ </table>
870+ */
871+ public ApiResponse <Void > automationTriggerWithHttpInfo (String accountId , String id , String xPhraseAppOTP ) throws ApiException {
872+ okhttp3 .Call localVarCall = automationTriggerValidateBeforeCall (accountId , id , xPhraseAppOTP , null );
873+ return localVarApiClient .execute (localVarCall );
874+ }
875+
876+ /**
877+ * Trigger an automation (asynchronously)
878+ * Trigger an automation.
879+ * @param accountId Account ID (required)
880+ * @param id ID (required)
881+ * @param xPhraseAppOTP Two-Factor-Authentication token (optional) (optional)
882+ * @param _callback The callback to be executed when the API call finishes
883+ * @return The request call
884+ * @throws ApiException If fail to process the API call, e.g. serializing the request body object
885+ * @http.response.details
886+ <table summary="Response Details" border="1">
887+ <tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
888+ <tr><td> 204 </td><td> The resource was deleted successfully. </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
889+ <tr><td> 400 </td><td> Bad request </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
890+ <tr><td> 404 </td><td> Not Found </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
891+ <tr><td> 429 </td><td> Rate Limiting </td><td> * X-Rate-Limit-Limit - <br> * X-Rate-Limit-Remaining - <br> * X-Rate-Limit-Reset - <br> </td></tr>
892+ </table>
893+ */
894+ public okhttp3 .Call automationTriggerAsync (String accountId , String id , String xPhraseAppOTP , final ApiCallback <Void > _callback ) throws ApiException {
895+
896+ okhttp3 .Call localVarCall = automationTriggerValidateBeforeCall (accountId , id , xPhraseAppOTP , _callback );
897+ localVarApiClient .executeAsync (localVarCall , _callback );
898+ return localVarCall ;
899+ }
763900 /**
764901 * Build call for automationUpdate
765902 * @param accountId Account ID (required)
0 commit comments