travel.wink.sdk.affiliate.sales.channel.api.RelationshipRequestApi Maven / Gradle / Ivy
Show all versions of affiliate-sales-channel-sdk-java Show documentation
package travel.wink.sdk.affiliate.sales.channel.api;
import travel.wink.sdk.affiliate.sales.channel.invoker.ApiClient;
import travel.wink.sdk.affiliate.sales.channel.model.BrowseSuppliers400Response;
import travel.wink.sdk.affiliate.sales.channel.model.GenericErrorMessage;
import travel.wink.sdk.affiliate.sales.channel.model.RemoveEntryResponse;
import travel.wink.sdk.affiliate.sales.channel.model.SalesChannelRelationshipRequestView;
import travel.wink.sdk.affiliate.sales.channel.model.SalesChannelRelationshipRequestViewAffiliate;
import travel.wink.sdk.affiliate.sales.channel.model.UpsertSalesChannelRelationshipRequestRequest;
import java.util.HashMap;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.stream.Collectors;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.LinkedMultiValueMap;
import org.springframework.util.MultiValueMap;
import org.springframework.core.ParameterizedTypeReference;
import org.springframework.web.reactive.function.client.WebClient.ResponseSpec;
import org.springframework.web.reactive.function.client.WebClientResponseException;
import org.springframework.core.io.FileSystemResource;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpStatus;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import reactor.core.publisher.Mono;
import reactor.core.publisher.Flux;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2024-10-04T20:20:44.711838495+07:00[Asia/Bangkok]")
public class RelationshipRequestApi {
private ApiClient apiClient;
public RelationshipRequestApi() {
this(new ApiClient());
}
@Autowired
public RelationshipRequestApi(ApiClient apiClient) {
this.apiClient = apiClient;
}
public ApiClient getApiClient() {
return apiClient;
}
public void setApiClient(ApiClient apiClient) {
this.apiClient = apiClient;
}
/**
* Create Supplier Request
* Create a new property request.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
201 - Created
* @param companyIdentifier Create property request and associate it with this company identifier
* @param upsertSalesChannelRelationshipRequestRequest The upsertSalesChannelRelationshipRequestRequest parameter
* @param winkVersion The winkVersion parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
private ResponseSpec createSupplierRequestRequestCreation(String companyIdentifier, UpsertSalesChannelRelationshipRequestRequest upsertSalesChannelRelationshipRequestRequest, String winkVersion) throws WebClientResponseException {
Object postBody = upsertSalesChannelRelationshipRequestRequest;
// verify the required parameter 'companyIdentifier' is set
if (companyIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'companyIdentifier' when calling createSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// verify the required parameter 'upsertSalesChannelRelationshipRequestRequest' is set
if (upsertSalesChannelRelationshipRequestRequest == null) {
throw new WebClientResponseException("Missing the required parameter 'upsertSalesChannelRelationshipRequestRequest' when calling createSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// create path and map variables
final Map pathParams = new HashMap();
pathParams.put("companyIdentifier", companyIdentifier);
final MultiValueMap queryParams = new LinkedMultiValueMap();
final HttpHeaders headerParams = new HttpHeaders();
final MultiValueMap cookieParams = new LinkedMultiValueMap();
final MultiValueMap formParams = new LinkedMultiValueMap();
if (winkVersion != null)
headerParams.add("Wink-Version", apiClient.parameterToString(winkVersion));
final String[] localVarAccepts = {
"application/json", "application/xml", "text/xml", "text/plain", "*/*"
};
final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = {
"application/json"
};
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] { "oauth2ClientCredentials" };
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return apiClient.invokeAPI("/api/affiliate/{companyIdentifier}/sales-channel/request", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
}
/**
* Create Supplier Request
* Create a new property request.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
201 - Created
* @param companyIdentifier Create property request and associate it with this company identifier
* @param upsertSalesChannelRelationshipRequestRequest The upsertSalesChannelRelationshipRequestRequest parameter
* @param winkVersion The winkVersion parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono createSupplierRequest(String companyIdentifier, UpsertSalesChannelRelationshipRequestRequest upsertSalesChannelRelationshipRequestRequest, String winkVersion) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return createSupplierRequestRequestCreation(companyIdentifier, upsertSalesChannelRelationshipRequestRequest, winkVersion).bodyToMono(localVarReturnType);
}
/**
* Create Supplier Request
* Create a new property request.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
201 - Created
* @param companyIdentifier Create property request and associate it with this company identifier
* @param upsertSalesChannelRelationshipRequestRequest The upsertSalesChannelRelationshipRequestRequest parameter
* @param winkVersion The winkVersion parameter
* @return ResponseEntity<SalesChannelRelationshipRequestView>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono> createSupplierRequestWithHttpInfo(String companyIdentifier, UpsertSalesChannelRelationshipRequestRequest upsertSalesChannelRelationshipRequestRequest, String winkVersion) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return createSupplierRequestRequestCreation(companyIdentifier, upsertSalesChannelRelationshipRequestRequest, winkVersion).toEntity(localVarReturnType);
}
/**
* Create Supplier Request
* Create a new property request.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
201 - Created
* @param companyIdentifier Create property request and associate it with this company identifier
* @param upsertSalesChannelRelationshipRequestRequest The upsertSalesChannelRelationshipRequestRequest parameter
* @param winkVersion The winkVersion parameter
* @return ResponseSpec
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public ResponseSpec createSupplierRequestWithResponseSpec(String companyIdentifier, UpsertSalesChannelRelationshipRequestRequest upsertSalesChannelRelationshipRequestRequest, String winkVersion) throws WebClientResponseException {
return createSupplierRequestRequestCreation(companyIdentifier, upsertSalesChannelRelationshipRequestRequest, winkVersion);
}
/**
* Re-apply Supplier Request
* Allows the affiliate to re-apply a previously rejected property request after 90 days.
*
500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Re-apply relationship request owned by this company identifier
* @param salesChannelRequestIdentifier Re-apply relationship request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
private ResponseSpec reApplySupplierRequestRequestCreation(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
Object postBody = null;
// verify the required parameter 'companyIdentifier' is set
if (companyIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'companyIdentifier' when calling reApplySupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// verify the required parameter 'salesChannelRequestIdentifier' is set
if (salesChannelRequestIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'salesChannelRequestIdentifier' when calling reApplySupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// create path and map variables
final Map pathParams = new HashMap();
pathParams.put("companyIdentifier", companyIdentifier);
pathParams.put("salesChannelRequestIdentifier", salesChannelRequestIdentifier);
final MultiValueMap queryParams = new LinkedMultiValueMap();
final HttpHeaders headerParams = new HttpHeaders();
final MultiValueMap cookieParams = new LinkedMultiValueMap();
final MultiValueMap formParams = new LinkedMultiValueMap();
if (winkVersion != null)
headerParams.add("Wink-Version", apiClient.parameterToString(winkVersion));
if (accept != null)
headerParams.add("Accept", apiClient.parameterToString(accept));
final String[] localVarAccepts = {
"application/json", "application/xml", "text/xml", "text/plain", "*/*"
};
final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = { };
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] { "oauth2ClientCredentials" };
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return apiClient.invokeAPI("/api/affiliate/{companyIdentifier}/sales-channel/request/{salesChannelRequestIdentifier}/re-apply", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
}
/**
* Re-apply Supplier Request
* Allows the affiliate to re-apply a previously rejected property request after 90 days.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Re-apply relationship request owned by this company identifier
* @param salesChannelRequestIdentifier Re-apply relationship request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono reApplySupplierRequest(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return reApplySupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept).bodyToMono(localVarReturnType);
}
/**
* Re-apply Supplier Request
* Allows the affiliate to re-apply a previously rejected property request after 90 days.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Re-apply relationship request owned by this company identifier
* @param salesChannelRequestIdentifier Re-apply relationship request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseEntity<SalesChannelRelationshipRequestView>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono> reApplySupplierRequestWithHttpInfo(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return reApplySupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept).toEntity(localVarReturnType);
}
/**
* Re-apply Supplier Request
* Allows the affiliate to re-apply a previously rejected property request after 90 days.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Re-apply relationship request owned by this company identifier
* @param salesChannelRequestIdentifier Re-apply relationship request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseSpec
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public ResponseSpec reApplySupplierRequestWithResponseSpec(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
return reApplySupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept);
}
/**
* Delete Relationship Request
* Delete a relationship request
*
500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Remove property request owned by this company identifier
* @param salesChannelRequestIdentifier Remove property request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return RemoveEntryResponse
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
private ResponseSpec removeSupplierRequestRequestCreation(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
Object postBody = null;
// verify the required parameter 'companyIdentifier' is set
if (companyIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'companyIdentifier' when calling removeSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// verify the required parameter 'salesChannelRequestIdentifier' is set
if (salesChannelRequestIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'salesChannelRequestIdentifier' when calling removeSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// create path and map variables
final Map pathParams = new HashMap();
pathParams.put("companyIdentifier", companyIdentifier);
pathParams.put("salesChannelRequestIdentifier", salesChannelRequestIdentifier);
final MultiValueMap queryParams = new LinkedMultiValueMap();
final HttpHeaders headerParams = new HttpHeaders();
final MultiValueMap cookieParams = new LinkedMultiValueMap();
final MultiValueMap formParams = new LinkedMultiValueMap();
if (winkVersion != null)
headerParams.add("Wink-Version", apiClient.parameterToString(winkVersion));
if (accept != null)
headerParams.add("Accept", apiClient.parameterToString(accept));
final String[] localVarAccepts = {
"application/json", "application/xml", "text/xml", "text/plain", "*/*"
};
final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = { };
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] { "oauth2ClientCredentials" };
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return apiClient.invokeAPI("/api/affiliate/{companyIdentifier}/sales-channel/request/{salesChannelRequestIdentifier}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
}
/**
* Delete Relationship Request
* Delete a relationship request
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Remove property request owned by this company identifier
* @param salesChannelRequestIdentifier Remove property request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return RemoveEntryResponse
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono removeSupplierRequest(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return removeSupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept).bodyToMono(localVarReturnType);
}
/**
* Delete Relationship Request
* Delete a relationship request
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Remove property request owned by this company identifier
* @param salesChannelRequestIdentifier Remove property request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseEntity<RemoveEntryResponse>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono> removeSupplierRequestWithHttpInfo(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return removeSupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept).toEntity(localVarReturnType);
}
/**
* Delete Relationship Request
* Delete a relationship request
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Remove property request owned by this company identifier
* @param salesChannelRequestIdentifier Remove property request with this identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseSpec
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public ResponseSpec removeSupplierRequestWithResponseSpec(String companyIdentifier, String salesChannelRequestIdentifier, String winkVersion, String accept) throws WebClientResponseException {
return removeSupplierRequestRequestCreation(companyIdentifier, salesChannelRequestIdentifier, winkVersion, accept);
}
/**
* Show Supplier Request
* Retrieve a specific property request based on a companyId and a supplierId.
*
500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show property request for this company identifier
* @param supplierIdentifier Show property request for this supplier identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
private ResponseSpec showSupplierRequestRequestCreation(String companyIdentifier, String supplierIdentifier, String winkVersion, String accept) throws WebClientResponseException {
Object postBody = null;
// verify the required parameter 'companyIdentifier' is set
if (companyIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'companyIdentifier' when calling showSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// verify the required parameter 'supplierIdentifier' is set
if (supplierIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'supplierIdentifier' when calling showSupplierRequest", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// create path and map variables
final Map pathParams = new HashMap();
pathParams.put("companyIdentifier", companyIdentifier);
pathParams.put("supplierIdentifier", supplierIdentifier);
final MultiValueMap queryParams = new LinkedMultiValueMap();
final HttpHeaders headerParams = new HttpHeaders();
final MultiValueMap cookieParams = new LinkedMultiValueMap();
final MultiValueMap formParams = new LinkedMultiValueMap();
if (winkVersion != null)
headerParams.add("Wink-Version", apiClient.parameterToString(winkVersion));
if (accept != null)
headerParams.add("Accept", apiClient.parameterToString(accept));
final String[] localVarAccepts = {
"application/json", "application/xml", "text/xml", "text/plain", "*/*"
};
final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = { };
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] { "oauth2ClientCredentials" };
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return apiClient.invokeAPI("/api/affiliate/{companyIdentifier}/sales-channel/request/supplier/{supplierIdentifier}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
}
/**
* Show Supplier Request
* Retrieve a specific property request based on a companyId and a supplierId.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show property request for this company identifier
* @param supplierIdentifier Show property request for this supplier identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return SalesChannelRelationshipRequestView
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono showSupplierRequest(String companyIdentifier, String supplierIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return showSupplierRequestRequestCreation(companyIdentifier, supplierIdentifier, winkVersion, accept).bodyToMono(localVarReturnType);
}
/**
* Show Supplier Request
* Retrieve a specific property request based on a companyId and a supplierId.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show property request for this company identifier
* @param supplierIdentifier Show property request for this supplier identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseEntity<SalesChannelRelationshipRequestView>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono> showSupplierRequestWithHttpInfo(String companyIdentifier, String supplierIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return showSupplierRequestRequestCreation(companyIdentifier, supplierIdentifier, winkVersion, accept).toEntity(localVarReturnType);
}
/**
* Show Supplier Request
* Retrieve a specific property request based on a companyId and a supplierId.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show property request for this company identifier
* @param supplierIdentifier Show property request for this supplier identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseSpec
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public ResponseSpec showSupplierRequestWithResponseSpec(String companyIdentifier, String supplierIdentifier, String winkVersion, String accept) throws WebClientResponseException {
return showSupplierRequestRequestCreation(companyIdentifier, supplierIdentifier, winkVersion, accept);
}
/**
* Show Supplier Requests
* Retrieve list of all property requests for this company.
*
500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show all property requests for this company identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return List<SalesChannelRelationshipRequestViewAffiliate>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
private ResponseSpec showSupplierRequestsRequestCreation(String companyIdentifier, String winkVersion, String accept) throws WebClientResponseException {
Object postBody = null;
// verify the required parameter 'companyIdentifier' is set
if (companyIdentifier == null) {
throw new WebClientResponseException("Missing the required parameter 'companyIdentifier' when calling showSupplierRequests", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);
}
// create path and map variables
final Map pathParams = new HashMap();
pathParams.put("companyIdentifier", companyIdentifier);
final MultiValueMap queryParams = new LinkedMultiValueMap();
final HttpHeaders headerParams = new HttpHeaders();
final MultiValueMap cookieParams = new LinkedMultiValueMap();
final MultiValueMap formParams = new LinkedMultiValueMap();
if (winkVersion != null)
headerParams.add("Wink-Version", apiClient.parameterToString(winkVersion));
if (accept != null)
headerParams.add("Accept", apiClient.parameterToString(accept));
final String[] localVarAccepts = {
"application/json", "application/xml", "text/xml", "text/plain", "*/*"
};
final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
final String[] localVarContentTypes = { };
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
String[] localVarAuthNames = new String[] { "oauth2ClientCredentials" };
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return apiClient.invokeAPI("/api/affiliate/{companyIdentifier}/sales-channel/request/list", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
}
/**
* Show Supplier Requests
* Retrieve list of all property requests for this company.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show all property requests for this company identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return List<SalesChannelRelationshipRequestViewAffiliate>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Flux showSupplierRequests(String companyIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return showSupplierRequestsRequestCreation(companyIdentifier, winkVersion, accept).bodyToFlux(localVarReturnType);
}
/**
* Show Supplier Requests
* Retrieve list of all property requests for this company.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show all property requests for this company identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseEntity<List<SalesChannelRelationshipRequestViewAffiliate>>
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public Mono>> showSupplierRequestsWithHttpInfo(String companyIdentifier, String winkVersion, String accept) throws WebClientResponseException {
ParameterizedTypeReference localVarReturnType = new ParameterizedTypeReference() {};
return showSupplierRequestsRequestCreation(companyIdentifier, winkVersion, accept).toEntityList(localVarReturnType);
}
/**
* Show Supplier Requests
* Retrieve list of all property requests for this company.
* 500 - Internal Server Error
*
403 - Forbidden
*
401 - Unauthorized
*
400 - Bad Request
*
200 - OK
* @param companyIdentifier Show all property requests for this company identifier
* @param winkVersion The winkVersion parameter
* @param accept The accept parameter
* @return ResponseSpec
* @throws WebClientResponseException if an error occurs while attempting to invoke the API
*/
public ResponseSpec showSupplierRequestsWithResponseSpec(String companyIdentifier, String winkVersion, String accept) throws WebClientResponseException {
return showSupplierRequestsRequestCreation(companyIdentifier, winkVersion, accept);
}
}