Skip to content

Commit bf80322

Browse files
author
awstools
committed
feat(client-partnercentral-selling): Added support for filtering opportunities by target close date in the ListOpportunities API. You can now filter results to return opportunities with a target close date before or after a specified date, enabling more precise opportunity searches based on expected closure timelines.
1 parent 5aaa8bc commit bf80322

File tree

6 files changed

+44
-4
lines changed

6 files changed

+44
-4
lines changed

clients/client-partnercentral-selling/src/commands/ListOpportunitiesCommand.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export interface ListOpportunitiesCommandOutput extends ListOpportunitiesRespons
4646
* NextToken: "STRING_VALUE",
4747
* Sort: { // OpportunitySort
4848
* SortOrder: "ASCENDING" || "DESCENDING", // required
49-
* SortBy: "LastModifiedDate" || "Identifier" || "CustomerCompanyName" || "CreatedDate", // required
49+
* SortBy: "LastModifiedDate" || "Identifier" || "CustomerCompanyName" || "CreatedDate" || "TargetCloseDate", // required
5050
* },
5151
* LastModifiedDate: { // LastModifiedDate
5252
* AfterLastModifiedDate: new Date("TIMESTAMP"),
@@ -68,6 +68,10 @@ export interface ListOpportunitiesCommandOutput extends ListOpportunitiesRespons
6868
* AfterCreatedDate: new Date("TIMESTAMP"),
6969
* BeforeCreatedDate: new Date("TIMESTAMP"),
7070
* },
71+
* TargetCloseDate: { // TargetCloseDateFilter
72+
* AfterTargetCloseDate: "STRING_VALUE",
73+
* BeforeTargetCloseDate: "STRING_VALUE",
74+
* },
7175
* };
7276
* const command = new ListOpportunitiesCommand(input);
7377
* const response = await client.send(command);

clients/client-partnercentral-selling/src/models/enums.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1175,6 +1175,7 @@ export const OpportunitySortName = {
11751175
CUSTOMER_COMPANY_NAME: "CustomerCompanyName",
11761176
IDENTIFIER: "Identifier",
11771177
LAST_MODIFIEDDATE: "LastModifiedDate",
1178+
TARGET_CLOSE_DATE: "TargetCloseDate",
11781179
} as const;
11791180
/**
11801181
* @public

clients/client-partnercentral-selling/src/models/models_0.ts

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2349,7 +2349,7 @@ export interface CreateEngagementInvitationRequest {
23492349
EngagementIdentifier: string | undefined;
23502350

23512351
/**
2352-
* <p> The <code>Invitation</code> object all information necessary to initiate an engagement invitation to a partner. It contains a personalized message from the sender, the invitation's receiver, and a payload. The <code>Payload</code> can be the <code>OpportunityInvitation</code>, which includes detailed structures for sender contacts, partner responsibilities, customer information, and project details. </p>
2352+
* <p> The <code>Invitation</code> object all information necessary to initiate an engagement invitation to a partner. It contains a personalized message from the sender, the invitation's receiver, and a payload. The <code>Payload</code> can be the <code>OpportunityInvitation</code>, which includes detailed structures for sender contacts, partner responsibilities, customer information, and project details, or <code>LeadInvitation</code>, which includes structures for customer information and interaction details. </p>
23532353
* @public
23542354
*/
23552355
Invitation: Invitation | undefined;
@@ -3460,6 +3460,24 @@ export interface OpportunitySort {
34603460
SortBy: OpportunitySortName | undefined;
34613461
}
34623462

3463+
/**
3464+
* <p>Filters opportunities based on their target close date.</p>
3465+
* @public
3466+
*/
3467+
export interface TargetCloseDateFilter {
3468+
/**
3469+
* <p>Filters opportunities with a target close date after this date. Use the <code>YYYY-MM-DD</code> format.</p>
3470+
* @public
3471+
*/
3472+
AfterTargetCloseDate?: string | undefined;
3473+
3474+
/**
3475+
* <p>Filters opportunities with a target close date before this date. Use the <code>YYYY-MM-DD</code> format.</p>
3476+
* @public
3477+
*/
3478+
BeforeTargetCloseDate?: string | undefined;
3479+
}
3480+
34633481
/**
34643482
* @public
34653483
*/
@@ -3523,6 +3541,12 @@ export interface ListOpportunitiesRequest {
35233541
* @public
35243542
*/
35253543
CreatedDate?: CreatedDateFilter | undefined;
3544+
3545+
/**
3546+
* <p>Filters opportunities based on their target close date. This filter helps retrieve opportunities with an expected close date before or after a specified date.</p>
3547+
* @public
3548+
*/
3549+
TargetCloseDate?: TargetCloseDateFilter | undefined;
35263550
}
35273551

35283552
/**

clients/client-partnercentral-selling/src/schemas/schemas_0.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ const _AR = "AccountReceiver";
4141
const _AS = "AccountSummary";
4242
const _ASd = "AddressSummary";
4343
const _ASw = "AwsSubmission";
44+
const _ATCD = "AfterTargetCloseDate";
4445
const _ATM = "AwsTeamMember";
4546
const _AWS = "AWS";
4647
const _Ac = "Account";
@@ -52,6 +53,7 @@ const _BCD = "BeforeCreatedDate";
5253
const _BLMD = "BeforeLastModifiedDate";
5354
const _BP = "BusinessProblem";
5455
const _BT = "BusinessTitle";
56+
const _BTCD = "BeforeTargetCloseDate";
5557
const _C = "Catalog";
5658
const _CA = "CreatedAt";
5759
const _CAu = "CustomerAction";
@@ -396,6 +398,7 @@ const _TABC = "TotalAmountByCategory";
396398
const _TAa = "TaskArn";
397399
const _TC = "TargetCompany";
398400
const _TCD = "TargetCloseDate";
401+
const _TCDF = "TargetCloseDateFilter";
399402
const _TCDa = "TargetCompletionDate";
400403
const _TE = "ThrottlingException";
401404
const _TI = "TaskIdentifier";
@@ -992,8 +995,8 @@ export var ListEngagementsResponse$: StaticStructureSchema = [3, n0, _LERi,
992995
];
993996
export var ListOpportunitiesRequest$: StaticStructureSchema = [3, n0, _LOR,
994997
0,
995-
[_C, _MR, _NT, _Sor, _LMD, _I, _LCSi, _LCRS, _CCN, _CD],
996-
[0, 1, 0, () => OpportunitySort$, () => LastModifiedDate$, 64 | 0, 64 | 0, 64 | 0, 64 | 0, () => CreatedDateFilter$], 1
998+
[_C, _MR, _NT, _Sor, _LMD, _I, _LCSi, _LCRS, _CCN, _CD, _TCD],
999+
[0, 1, 0, () => OpportunitySort$, () => LastModifiedDate$, 64 | 0, 64 | 0, 64 | 0, 64 | 0, () => CreatedDateFilter$, () => TargetCloseDateFilter$], 1
9971000
];
9981001
export var ListOpportunitiesResponse$: StaticStructureSchema = [3, n0, _LORi,
9991002
0,
@@ -1240,6 +1243,11 @@ export var TagResourceResponse$: StaticStructureSchema = [3, n0, _TRRa,
12401243
[],
12411244
[]
12421245
];
1246+
export var TargetCloseDateFilter$: StaticStructureSchema = [3, n0, _TCDF,
1247+
0,
1248+
[_ATCD, _BTCD],
1249+
[0, 0]
1250+
];
12431251
export var UntagResourceRequest$: StaticStructureSchema = [3, n0, _URR,
12441252
0,
12451253
[_RA, _TK],

clients/client-partnercentral-selling/test/index-objects.spec.mjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,7 @@ import {
289289
TagResourceCommand,
290290
TagResourceRequest$,
291291
TagResourceResponse$,
292+
TargetCloseDateFilter$,
292293
TaskStatus,
293294
ThrottlingException,
294295
ThrottlingException$,
@@ -547,6 +548,7 @@ assert(typeof SubmitOpportunityRequest$ === "object");
547548
assert(typeof Tag$ === "object");
548549
assert(typeof TagResourceRequest$ === "object");
549550
assert(typeof TagResourceResponse$ === "object");
551+
assert(typeof TargetCloseDateFilter$ === "object");
550552
assert(typeof UntagResourceRequest$ === "object");
551553
assert(typeof UntagResourceResponse$ === "object");
552554
assert(typeof UpdateEngagementContextPayload$ === "object");

clients/client-partnercentral-selling/test/index-types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,7 @@ export type {
320320
Tag,
321321
TagResourceRequest,
322322
TagResourceResponse,
323+
TargetCloseDateFilter,
323324
UntagResourceRequest,
324325
UntagResourceResponse,
325326
UpdateEngagementContextPayload,

0 commit comments

Comments
 (0)