Interface MarketplaceAgreementAsyncClient

  • All Superinterfaces:
    AutoCloseable, AwsClient, SdkAutoCloseable, SdkClient

    @Generated("software.amazon.awssdk:codegen")
    @ThreadSafe
    public interface MarketplaceAgreementAsyncClient
    extends AwsClient
    Service client for accessing Agreement Service asynchronously. This can be created using the static builder() method.

    AWS Marketplace is a curated digital catalog that customers can use to find, buy, deploy, and manage third-party software, data, and services to build solutions and run their businesses. The AWS Marketplace Agreement Service provides an API interface that helps AWS Marketplace sellers manage their product-related agreements, including listing, searching, and filtering agreements.

    To manage agreements in AWS Marketplace, you must ensure that your AWS Identity and Access Management (IAM) policies and roles are set up. The user must have the required policies/permissions that allow them to carry out the actions in AWS:

    • DescribeAgreement – Grants permission to users to obtain detailed meta data about any of their agreements.

    • GetAgreementTerms – Grants permission to users to obtain details about the terms of an agreement.

    • SearchAgreements – Grants permission to users to search through all their agreements.

    • Method Detail

      • describeAgreement

        default CompletableFuture<DescribeAgreementResponse> describeAgreement​(DescribeAgreementRequest describeAgreementRequest)

        Provides details about an agreement, such as the proposer, acceptor, start date, and end date.

        Parameters:
        describeAgreementRequest -
        Returns:
        A Java Future containing the result of the DescribeAgreement operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • describeAgreement

        default CompletableFuture<DescribeAgreementResponse> describeAgreement​(Consumer<DescribeAgreementRequest.Builder> describeAgreementRequest)

        Provides details about an agreement, such as the proposer, acceptor, start date, and end date.


        This is a convenience which creates an instance of the DescribeAgreementRequest.Builder avoiding the need to create one manually via DescribeAgreementRequest.builder()

        Parameters:
        describeAgreementRequest - A Consumer that will call methods on DescribeAgreementRequest.Builder to create a request.
        Returns:
        A Java Future containing the result of the DescribeAgreement operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • getAgreementTerms

        default CompletableFuture<GetAgreementTermsResponse> getAgreementTerms​(GetAgreementTermsRequest getAgreementTermsRequest)

        Obtains details about the terms in an agreement that you participated in as proposer or acceptor.

        The details include:

        • TermType – The type of term, such as LegalTerm, RenewalTerm, or ConfigurableUpfrontPricingTerm.

        • TermID – The ID of the particular term, which is common between offer and agreement.

        • TermPayload – The key information contained in the term, such as the EULA for LegalTerm or pricing and dimensions for various pricing terms, such as ConfigurableUpfrontPricingTerm or UsageBasedPricingTerm.

        • Configuration – The buyer/acceptor's selection at the time of agreement creation, such as the number of units purchased for a dimension or setting the EnableAutoRenew flag.

        Parameters:
        getAgreementTermsRequest -
        Returns:
        A Java Future containing the result of the GetAgreementTerms operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • getAgreementTerms

        default CompletableFuture<GetAgreementTermsResponse> getAgreementTerms​(Consumer<GetAgreementTermsRequest.Builder> getAgreementTermsRequest)

        Obtains details about the terms in an agreement that you participated in as proposer or acceptor.

        The details include:

        • TermType – The type of term, such as LegalTerm, RenewalTerm, or ConfigurableUpfrontPricingTerm.

        • TermID – The ID of the particular term, which is common between offer and agreement.

        • TermPayload – The key information contained in the term, such as the EULA for LegalTerm or pricing and dimensions for various pricing terms, such as ConfigurableUpfrontPricingTerm or UsageBasedPricingTerm.

        • Configuration – The buyer/acceptor's selection at the time of agreement creation, such as the number of units purchased for a dimension or setting the EnableAutoRenew flag.


        This is a convenience which creates an instance of the GetAgreementTermsRequest.Builder avoiding the need to create one manually via GetAgreementTermsRequest.builder()

        Parameters:
        getAgreementTermsRequest - A Consumer that will call methods on GetAgreementTermsRequest.Builder to create a request.
        Returns:
        A Java Future containing the result of the GetAgreementTerms operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • getAgreementTermsPaginator

        default GetAgreementTermsPublisher getAgreementTermsPaginator​(GetAgreementTermsRequest getAgreementTermsRequest)

        This is a variant of getAgreementTerms(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

        When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

        The following are few ways to use the response class:

        1) Using the subscribe helper method
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.GetAgreementTermsPublisher publisher = client.getAgreementTermsPaginator(request);
         CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
         future.get();
         
         
        2) Using a custom subscriber
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.GetAgreementTermsPublisher publisher = client.getAgreementTermsPaginator(request);
         publisher.subscribe(new Subscriber<software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsResponse>() {
         
         public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
         
         
         public void onNext(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsResponse response) { //... };
         });
         
        As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

        Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.

        Note: If you prefer to have control on service calls, use the getAgreementTerms(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsRequest) operation.

        Parameters:
        getAgreementTermsRequest -
        Returns:
        A custom publisher that can be subscribed to request a stream of response pages.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • getAgreementTermsPaginator

        default GetAgreementTermsPublisher getAgreementTermsPaginator​(Consumer<GetAgreementTermsRequest.Builder> getAgreementTermsRequest)

        This is a variant of getAgreementTerms(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

        When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

        The following are few ways to use the response class:

        1) Using the subscribe helper method
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.GetAgreementTermsPublisher publisher = client.getAgreementTermsPaginator(request);
         CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
         future.get();
         
         
        2) Using a custom subscriber
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.GetAgreementTermsPublisher publisher = client.getAgreementTermsPaginator(request);
         publisher.subscribe(new Subscriber<software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsResponse>() {
         
         public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
         
         
         public void onNext(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsResponse response) { //... };
         });
         
        As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

        Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.

        Note: If you prefer to have control on service calls, use the getAgreementTerms(software.amazon.awssdk.services.marketplaceagreement.model.GetAgreementTermsRequest) operation.


        This is a convenience which creates an instance of the GetAgreementTermsRequest.Builder avoiding the need to create one manually via GetAgreementTermsRequest.builder()

        Parameters:
        getAgreementTermsRequest - A Consumer that will call methods on GetAgreementTermsRequest.Builder to create a request.
        Returns:
        A custom publisher that can be subscribed to request a stream of response pages.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • ResourceNotFoundException Request references a resource which does not exist.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • searchAgreements

        default CompletableFuture<SearchAgreementsResponse> searchAgreements​(SearchAgreementsRequest searchAgreementsRequest)

        Searches across all agreements that a proposer or an acceptor has in AWS Marketplace. The search returns a list of agreements with basic agreement information.

        The following filter combinations are supported:

        • PartyType as Proposer + AgreementType + ResourceIdentifier

        • PartyType as Proposer + AgreementType + OfferId

        • PartyType as Proposer + AgreementType + AcceptorAccountId

        • PartyType as Proposer + AgreementType + Status

        • PartyType as Proposer + AgreementType + ResourceIdentifier + Status

        • PartyType as Proposer + AgreementType + OfferId + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + Status

        • PartyType as Proposer + AgreementType + ResourceType + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceType + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + OfferId

        • PartyType as Proposer + AgreementType + AcceptorAccountId + OfferId + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceIdentifier

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceIdentifier + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceType

        Parameters:
        searchAgreementsRequest -
        Returns:
        A Java Future containing the result of the SearchAgreements operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • searchAgreements

        default CompletableFuture<SearchAgreementsResponse> searchAgreements​(Consumer<SearchAgreementsRequest.Builder> searchAgreementsRequest)

        Searches across all agreements that a proposer or an acceptor has in AWS Marketplace. The search returns a list of agreements with basic agreement information.

        The following filter combinations are supported:

        • PartyType as Proposer + AgreementType + ResourceIdentifier

        • PartyType as Proposer + AgreementType + OfferId

        • PartyType as Proposer + AgreementType + AcceptorAccountId

        • PartyType as Proposer + AgreementType + Status

        • PartyType as Proposer + AgreementType + ResourceIdentifier + Status

        • PartyType as Proposer + AgreementType + OfferId + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + Status

        • PartyType as Proposer + AgreementType + ResourceType + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceType + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + OfferId

        • PartyType as Proposer + AgreementType + AcceptorAccountId + OfferId + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceIdentifier

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceIdentifier + Status

        • PartyType as Proposer + AgreementType + AcceptorAccountId + ResourceType


        This is a convenience which creates an instance of the SearchAgreementsRequest.Builder avoiding the need to create one manually via SearchAgreementsRequest.builder()

        Parameters:
        searchAgreementsRequest - A Consumer that will call methods on SearchAgreementsRequest.Builder to create a request.
        Returns:
        A Java Future containing the result of the SearchAgreements operation returned by the service.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • searchAgreementsPaginator

        default SearchAgreementsPublisher searchAgreementsPaginator​(SearchAgreementsRequest searchAgreementsRequest)

        This is a variant of searchAgreements(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

        When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

        The following are few ways to use the response class:

        1) Using the subscribe helper method
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.SearchAgreementsPublisher publisher = client.searchAgreementsPaginator(request);
         CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
         future.get();
         
         
        2) Using a custom subscriber
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.SearchAgreementsPublisher publisher = client.searchAgreementsPaginator(request);
         publisher.subscribe(new Subscriber<software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsResponse>() {
         
         public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
         
         
         public void onNext(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsResponse response) { //... };
         });
         
        As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

        Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.

        Note: If you prefer to have control on service calls, use the searchAgreements(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsRequest) operation.

        Parameters:
        searchAgreementsRequest -
        Returns:
        A custom publisher that can be subscribed to request a stream of response pages.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation
      • searchAgreementsPaginator

        default SearchAgreementsPublisher searchAgreementsPaginator​(Consumer<SearchAgreementsRequest.Builder> searchAgreementsRequest)

        This is a variant of searchAgreements(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

        When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

        The following are few ways to use the response class:

        1) Using the subscribe helper method
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.SearchAgreementsPublisher publisher = client.searchAgreementsPaginator(request);
         CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
         future.get();
         
         
        2) Using a custom subscriber
         
         software.amazon.awssdk.services.marketplaceagreement.paginators.SearchAgreementsPublisher publisher = client.searchAgreementsPaginator(request);
         publisher.subscribe(new Subscriber<software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsResponse>() {
         
         public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
         
         
         public void onNext(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsResponse response) { //... };
         });
         
        As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

        Please notice that the configuration of maxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.

        Note: If you prefer to have control on service calls, use the searchAgreements(software.amazon.awssdk.services.marketplaceagreement.model.SearchAgreementsRequest) operation.


        This is a convenience which creates an instance of the SearchAgreementsRequest.Builder avoiding the need to create one manually via SearchAgreementsRequest.builder()

        Parameters:
        searchAgreementsRequest - A Consumer that will call methods on SearchAgreementsRequest.Builder to create a request.
        Returns:
        A custom publisher that can be subscribed to request a stream of response pages.
        The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
        • ValidationException The input fails to satisfy the constraints specified by the service.
        • AccessDeniedException User does not have sufficient access to perform this action.
        • ThrottlingException Request was denied due to request throttling.
        • InternalServerException Unexpected error during processing of request.
        • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
        • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
        • MarketplaceAgreementException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
        See Also:
        AWS API Documentation