list_opportunities
async
¶
list_opportunities(
catalog: CatalogIdentifier,
*,
config_overrides: Optional[AsyncPartnerCentralSellingClientConfig] = None,
max_results: Optional[PageSize] = None,
next_token: Optional[str] = None,
sort: Optional[OpportunitySort] = None,
last_modified_date: Optional[LastModifiedDate] = None,
identifier: Optional[FilterIdentifier] = None,
life_cycle_stage: Optional[FilterLifeCycleStage] = None,
life_cycle_review_status: Optional[FilterLifeCycleReviewStatus] = None,
customer_company_name: Optional[StringList] = None,
created_date: Optional[CreatedDateFilter] = None,
target_close_date: Optional[TargetCloseDateFilter] = None,
) -> ListOpportunitiesResponse
This request accepts a list of filters that retrieve opportunity subsets as well as sort options. This feature is available to partners from Partner Central using the ListOpportunities API action.
To synchronize your system with Amazon Web Services, list only the opportunities that were newly created or updated. We recommend you rely on events emitted by the service into your Amazon Web Services account’s Amazon EventBridge default event bus. You can also use the ListOpportunities action.
We recommend the following approach:
-
Find the latest
LastModifiedDatethat you stored, and only use the values that came from Amazon Web Services. Don’t use values generated by your system. -
When you send a
ListOpportunitiesrequest, submit the date in ISO 8601 format in theAfterLastModifiedDatefilter. -
Amazon Web Services only returns opportunities created or updated on or after that date and time. Use
NextTokento iterate over all pages.
Parameters:
-
catalog(CatalogIdentifier) –Specifies the catalog associated with the request. This field takes a string value from a predefined list:
AWSorSandbox. The catalog determines which environment the opportunities are listed in. UseAWSfor listing real opportunities in the Amazon Web Services catalog, andSandboxfor testing in secure, isolated environments. -
max_results(Optional[PageSize], default:None) –Specifies the maximum number of results to return in a single call. This limits the number of opportunities returned in the response to avoid providing too many results at once.
Default: 20
-
next_token(Optional[str], default:None) –A pagination token used to retrieve the next set of results in subsequent calls. This token is included in the response only if there are additional result pages available.
-
sort(Optional[OpportunitySort], default:None) –An object that specifies how the response is sorted. The default
Sort.SortByvalue isLastModifiedDate. -
last_modified_date(Optional[LastModifiedDate], default:None) –Filters the opportunities based on their last modified date. This filter helps retrieve opportunities that were updated after the specified date, allowing partners to track recent changes or updates.
-
identifier(Optional[FilterIdentifier], default:None) –Filters the opportunities based on the opportunity identifier. This allows partners to retrieve specific opportunities by providing their unique identifiers, ensuring precise results.
-
life_cycle_stage(Optional[FilterLifeCycleStage], default:None) –Filters the opportunities based on their lifecycle stage. This filter allows partners to retrieve opportunities at various stages in the sales cycle, such as
Qualified,Technical Validation,Business Validation, orClosed Won. -
life_cycle_review_status(Optional[FilterLifeCycleReviewStatus], default:None) –Filters the opportunities based on their current lifecycle approval status. Use this filter to retrieve opportunities with statuses such as
Pending Submission,In Review,Action Required, orApproved. -
customer_company_name(Optional[StringList], default:None) –Filters the opportunities based on the customer's company name. This allows partners to search for opportunities associated with a specific customer by matching the provided company name string.
-
created_date(Optional[CreatedDateFilter], default:None) –Filter opportunities by creation date criteria.
-
target_close_date(Optional[TargetCloseDateFilter], default:None) –Filters opportunities based on their target close date. This filter helps retrieve opportunities with an expected close date before or after a specified date.
Raises:
-
AccessDeniedException–This error occurs when you don't have permission to perform the requested action.
You don’t have access to this action or resource. Review IAM policies or contact your AWS administrator for assistance.
-
InternalServerException–This error occurs when the specified resource can’t be found or doesn't exist. Resource ID and type might be incorrect.
Suggested action: This is usually a transient error. Retry after the provided retry delay or a short interval. If the problem persists, contact AWS support.
-
ResourceNotFoundException–This error occurs when the specified resource can't be found. The resource might not exist, or isn't visible with the current credentials.
Suggested action: Verify that the resource ID is correct and the resource is in the expected AWS region. Check IAM permissions for accessing the resource.
-
ThrottlingException–This error occurs when there are too many requests sent. Review the provided quotas and adapt your usage to avoid throttling.
This error occurs when there are too many requests sent. Review the provided Quotas and retry after the provided delay.
-
ValidationException–The input fails to satisfy the constraints specified by the service or business validation rules.
Suggested action: Review the error message, including the failed fields and reasons, to correct the request payload.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_partnercentral_selling/_services/async_partner_central_selling.py
3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 | |