SearchAgreements
Searches across all agreements that a proposer has in AWS Marketplace. The search returns a list of agreements with basic agreement information.
The following filter combinations are supported when the PartyType is Proposer:
-
AgreementType -
AgreementType+EndTime -
AgreementType+ResourceType -
AgreementType+ResourceType+EndTime -
AgreementType+ResourceType+Status -
AgreementType+ResourceType+Status+EndTime -
AgreementType+ResourceId -
AgreementType+ResourceId+EndTime -
AgreementType+ResourceId+Status -
AgreementType+ResourceId+Status+EndTime -
AgreementType+AcceptorAccountId -
AgreementType+AcceptorAccountId+EndTime -
AgreementType+AcceptorAccountId+Status -
AgreementType+AcceptorAccountId+Status+EndTime -
AgreementType+AcceptorAccountId+OfferId -
AgreementType+AcceptorAccountId+OfferId+Status -
AgreementType+AcceptorAccountId+OfferId+EndTime -
AgreementType+AcceptorAccountId+OfferId+Status+EndTime -
AgreementType+AcceptorAccountId+ResourceId -
AgreementType+AcceptorAccountId+ResourceId+Status -
AgreementType+AcceptorAccountId+ResourceId+EndTime -
AgreementType+AcceptorAccountId+ResourceId+Status+EndTime -
AgreementType+AcceptorAccountId+ResourceType -
AgreementType+AcceptorAccountId+ResourceType+EndTime -
AgreementType+AcceptorAccountId+ResourceType+Status -
AgreementType+AcceptorAccountId+ResourceType+Status+EndTime -
AgreementType+Status -
AgreementType+Status+EndTime -
AgreementType+OfferId -
AgreementType+OfferId+EndTime -
AgreementType+OfferId+Status -
AgreementType+OfferId+Status+EndTime
Note
To filter by EndTime, you can use either BeforeEndTime or
AfterEndTime. Only EndTime is supported for sorting.
Request Syntax
{
"catalog": "string",
"filters": [
{
"name": "string",
"values": [ "string" ]
}
],
"maxResults": number,
"nextToken": "string",
"sort": {
"sortBy": "string",
"sortOrder": "string"
}
}
Request Parameters
The request accepts the following data in JSON format.
Note
In the following list, the required parameters are described first.
- catalog
-
The catalog in which the agreement was created.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 64.
Pattern:
[a-zA-Z]+Required: No
- filters
-
The filter name and value pair used to return a specific list of results.
The following filters are supported:
-
ResourceIdentifier– The unique identifier of the resource. -
ResourceType– Type of the resource, which is the product (AmiProduct,ContainerProduct, orSaaSProduct). -
PartyType– The party type (eitherAcceptororProposer) of the caller. For agreements where the caller is the proposer, use theProposerfilter. For agreements where the caller is the acceptor, use theAcceptorfilter. -
AcceptorAccountId– The AWS account ID of the party accepting the agreement terms. -
OfferId– The unique identifier of the offer in which the terms are registered in the agreement token. -
Status– The current status of the agreement. Values includeACTIVE,ARCHIVED,CANCELLED,EXPIRED,RENEWED,REPLACED, andTERMINATED. -
BeforeEndTime– A date used to filter agreements with a date before theendTimeof an agreement. -
AfterEndTime– A date used to filter agreements with a date after theendTimeof an agreement. -
AgreementType– The type of agreement. Supported value includesPurchaseAgreement.
Type: Array of Filter objects
Array Members: Minimum number of 1 item. Maximum number of 10 items.
Required: No
-
- maxResults
-
The maximum number of agreements to return in the response.
Type: Integer
Valid Range: Minimum value of 1. Maximum value of 50.
Required: No
- nextToken
-
A token to specify where to start pagination.
Type: String
Length Constraints: Minimum length of 0. Maximum length of 8192.
Pattern:
[a-zA-Z0-9+/=]+Required: No
- sort
-
An object that contains the
SortByandSortOrderattributes. OnlyEndTimeis supported forSearchAgreements. The default sort isEndTimedescending.Type: Sort object
Required: No
Response Syntax
{
"agreementViewSummaries": [
{
"acceptanceTime": number,
"acceptor": {
"accountId": "string"
},
"agreementId": "string",
"agreementType": "string",
"endTime": number,
"proposalSummary": {
"offerId": "string",
"resources": [
{
"id": "string",
"type": "string"
}
]
},
"proposer": {
"accountId": "string"
},
"startTime": number,
"status": "string"
}
],
"nextToken": "string"
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- agreementViewSummaries
-
A summary of the agreement, including top-level attributes (for example, the agreement ID, proposer, and acceptor).
Type: Array of AgreementViewSummary objects
- nextToken
-
The token used for pagination. The field is
nullif there are no more results.Type: String
Length Constraints: Minimum length of 0. Maximum length of 8192.
Pattern:
[a-zA-Z0-9+/=]+
Errors
For information about the errors that are common to all actions, see Common Errors.
- AccessDeniedException
-
User does not have sufficient access to perform this action.
- requestId
-
The unique identifier for the error.
HTTP Status Code: 400
- InternalServerException
-
Unexpected error during processing of request.
- requestId
-
The unique identifier for the error.
HTTP Status Code: 500
- ThrottlingException
-
Request was denied due to request throttling.
- requestId
-
The unique identifier for the error.
HTTP Status Code: 400
- ValidationException
-
The input fails to satisfy the constraints specified by the service.
- fields
-
The fields associated with the error.
- reason
-
The reason associated with the error.
- requestId
-
The unique identifier associated with the error.
HTTP Status Code: 400
Examples
Sample request
This example illustrates one usage of SearchAgreements.
{ "catalog": "AWSMarketplace", "filters": [ { "name": "PartyType", "values": ["Proposer"] }, { "name": "AfterEndTime", "values": ["2019-10-08T00:00:00Z"] }, { "name": "AcceptorAccountId", "values": ["123456789010"] } ] }
Sample response
This example illustrates one usage of SearchAgreements.
{ "agreementViewSummaries": [ { "agreementId": "fEXAMPLE-0aa6-4e42-8715-6a1EXAMPLE95", "acceptor": { "accountId": "123456789010" }, "proposer": { "accountId": "123456789010" }, "startTime": 2019-10-08T21:40:43Z, "endTime": 2023-10-08T21:40:43Z, "acceptanceTime": 2019-10-08T00:00:00Z, "agreementType": "PurchaseAgreement", "proposalSummary": { "resources": [ { "id": "0EXAMPLE-8ce8-4814-bcf1-636EXAMPLEb5", "type": "AmiProduct" } ], "offerId": "ABCDEFGHIJKLMNOP123" }, "status": "ACTIVE" } ], "nextToken": null }
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: