Skip to content

Commit

Permalink
Removed sunseted operation from FlowAPI
Browse files Browse the repository at this point in the history
  • Loading branch information
ib-tjuhasz committed Dec 16, 2024
1 parent d91a964 commit f5253b5
Showing 1 changed file with 0 additions and 91 deletions.
91 changes: 0 additions & 91 deletions src/main/java/com/infobip/api/FlowApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -130,97 +130,6 @@ private RequestDefinition addPeopleToFlowDefinition(
return builder.build();
}

/**
* addPeopleToFlow request builder class.
*/
public class AddPeopleToFlowRequest {
private final Long campaignId;
private final FlowPersonRequest flowPersonRequest;
private String phone;
private String email;
private String externalId;

private AddPeopleToFlowRequest(Long campaignId, FlowPersonRequest flowPersonRequest) {
this.campaignId = Objects.requireNonNull(campaignId, "The required parameter 'campaignId' is missing.");
this.flowPersonRequest =
Objects.requireNonNull(flowPersonRequest, "The required parameter 'flowPersonRequest' is missing.");
}

/**
* Sets phone.
*
* @param phone Person's phone number (optional)
* @return AddPeopleToFlowRequest
*/
public AddPeopleToFlowRequest phone(String phone) {
this.phone = phone;
return this;
}

/**
* Sets email.
*
* @param email Person's email address (optional)
* @return AddPeopleToFlowRequest
*/
public AddPeopleToFlowRequest email(String email) {
this.email = email;
return this;
}

/**
* Sets externalId.
*
* @param externalId Unique ID for the person from an external system (optional)
* @return AddPeopleToFlowRequest
*/
public AddPeopleToFlowRequest externalId(String externalId) {
this.externalId = externalId;
return this;
}

/**
* Executes the addPeopleToFlow request
* @throws ApiException If the API call fails or an error occurs during the request or response processing.
* @deprecated
*/
@Deprecated
public void execute() throws ApiException {
RequestDefinition addPeopleToFlowDefinition =
addPeopleToFlowDefinition(campaignId, flowPersonRequest, phone, email, externalId);
apiClient.execute(addPeopleToFlowDefinition);
}

/**
* Executes the addPeopleToFlow request asynchronously.
*
* @param callback The {@link ApiCallback} to be invoked.
* @return The {@link okhttp3.Call} associated with the API request.
* @deprecated
*/
@Deprecated
public okhttp3.Call executeAsync(ApiCallback<Void> callback) {
RequestDefinition addPeopleToFlowDefinition =
addPeopleToFlowDefinition(campaignId, flowPersonRequest, phone, email, externalId);
return apiClient.executeAsync(addPeopleToFlowDefinition, callback);
}
}

/**
* Add Person to Flow.
* <p>
* Creates or updates a person and adds it to Flow
*
* @param campaignId Unique identifier of the flow that person will be added to (required)
* @param flowPersonRequest (required)
* @return AddPeopleToFlowRequest
* @deprecated
*/
@Deprecated
public AddPeopleToFlowRequest addPeopleToFlow(Long campaignId, FlowPersonRequest flowPersonRequest) {
return new AddPeopleToFlowRequest(campaignId, flowPersonRequest);
}

private RequestDefinition getFlowParticipantsAddedReportDefinition(Long campaignId, String operationId) {
RequestDefinition.Builder builder = RequestDefinition.builder(
"GET", "/moments/1/flows/{campaignId}/participants/report")
Expand Down

0 comments on commit f5253b5

Please sign in to comment.