@aws-sdk/client-sns 3.476.0 → 3.478.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/pagination/ListEndpointsByPlatformApplicationPaginator.js +2 -23
- package/dist-cjs/pagination/ListOriginationNumbersPaginator.js +2 -24
- package/dist-cjs/pagination/ListPhoneNumbersOptedOutPaginator.js +2 -23
- package/dist-cjs/pagination/ListPlatformApplicationsPaginator.js +2 -23
- package/dist-cjs/pagination/ListSMSSandboxPhoneNumbersPaginator.js +2 -24
- package/dist-cjs/pagination/ListSubscriptionsByTopicPaginator.js +2 -23
- package/dist-cjs/pagination/ListSubscriptionsPaginator.js +2 -23
- package/dist-cjs/pagination/ListTopicsPaginator.js +2 -23
- package/dist-cjs/protocols/Aws_query.js +604 -492
- package/dist-es/pagination/ListEndpointsByPlatformApplicationPaginator.js +2 -22
- package/dist-es/pagination/ListOriginationNumbersPaginator.js +2 -23
- package/dist-es/pagination/ListPhoneNumbersOptedOutPaginator.js +2 -22
- package/dist-es/pagination/ListPlatformApplicationsPaginator.js +2 -22
- package/dist-es/pagination/ListSMSSandboxPhoneNumbersPaginator.js +2 -23
- package/dist-es/pagination/ListSubscriptionsByTopicPaginator.js +2 -22
- package/dist-es/pagination/ListSubscriptionsPaginator.js +2 -22
- package/dist-es/pagination/ListTopicsPaginator.js +2 -22
- package/dist-es/protocols/Aws_query.js +604 -492
- package/dist-types/pagination/ListEndpointsByPlatformApplicationPaginator.d.ts +1 -1
- package/dist-types/pagination/ListOriginationNumbersPaginator.d.ts +1 -1
- package/dist-types/pagination/ListPhoneNumbersOptedOutPaginator.d.ts +1 -1
- package/dist-types/pagination/ListPlatformApplicationsPaginator.d.ts +1 -1
- package/dist-types/pagination/ListSMSSandboxPhoneNumbersPaginator.d.ts +1 -1
- package/dist-types/pagination/ListSubscriptionsByTopicPaginator.d.ts +1 -1
- package/dist-types/pagination/ListSubscriptionsPaginator.d.ts +1 -1
- package/dist-types/pagination/ListTopicsPaginator.d.ts +1 -1
- package/dist-types/ts3.4/pagination/ListEndpointsByPlatformApplicationPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListOriginationNumbersPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListPhoneNumbersOptedOutPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListPlatformApplicationsPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListSMSSandboxPhoneNumbersPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListSubscriptionsByTopicPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListSubscriptionsPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListTopicsPaginator.d.ts +3 -3
- package/package.json +7 -6
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListEndpointsByPlatformApplicationCommand, } from "../commands/ListEndpointsByPlatformApplicationCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListEndpointsByPlatformApplicationCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListEndpointsByPlatformApplication(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.NextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListEndpointsByPlatformApplication = createPaginator(SNSClient, ListEndpointsByPlatformApplicationCommand, "NextToken", "NextToken", "");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListOriginationNumbersCommand, } from "../commands/ListOriginationNumbersCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListOriginationNumbersCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListOriginationNumbers(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
input["MaxResults"] = config.pageSize;
|
|
13
|
-
if (config.client instanceof SNSClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.NextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateListOriginationNumbers = createPaginator(SNSClient, ListOriginationNumbersCommand, "NextToken", "NextToken", "MaxResults");
|
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListPhoneNumbersOptedOutCommand, } from "../commands/ListPhoneNumbersOptedOutCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListPhoneNumbersOptedOutCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListPhoneNumbersOptedOut(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.nextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.nextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListPhoneNumbersOptedOut = createPaginator(SNSClient, ListPhoneNumbersOptedOutCommand, "nextToken", "nextToken", "");
|
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListPlatformApplicationsCommand, } from "../commands/ListPlatformApplicationsCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListPlatformApplicationsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListPlatformApplications(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.NextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListPlatformApplications = createPaginator(SNSClient, ListPlatformApplicationsCommand, "NextToken", "NextToken", "");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListSMSSandboxPhoneNumbersCommand, } from "../commands/ListSMSSandboxPhoneNumbersCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListSMSSandboxPhoneNumbersCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListSMSSandboxPhoneNumbers(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
input["MaxResults"] = config.pageSize;
|
|
13
|
-
if (config.client instanceof SNSClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.NextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateListSMSSandboxPhoneNumbers = createPaginator(SNSClient, ListSMSSandboxPhoneNumbersCommand, "NextToken", "NextToken", "MaxResults");
|
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListSubscriptionsByTopicCommand, } from "../commands/ListSubscriptionsByTopicCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListSubscriptionsByTopicCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListSubscriptionsByTopic(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.NextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListSubscriptionsByTopic = createPaginator(SNSClient, ListSubscriptionsByTopicCommand, "NextToken", "NextToken", "");
|
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListSubscriptionsCommand, } from "../commands/ListSubscriptionsCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListSubscriptionsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListSubscriptions(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.NextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListSubscriptions = createPaginator(SNSClient, ListSubscriptionsCommand, "NextToken", "NextToken", "");
|
|
@@ -1,24 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { ListTopicsCommand } from "../commands/ListTopicsCommand";
|
|
2
3
|
import { SNSClient } from "../SNSClient";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListTopicsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListTopics(config, input, ...additionalArguments) {
|
|
7
|
-
let token = config.startingToken || undefined;
|
|
8
|
-
let hasNext = true;
|
|
9
|
-
let page;
|
|
10
|
-
while (hasNext) {
|
|
11
|
-
input.NextToken = token;
|
|
12
|
-
if (config.client instanceof SNSClient) {
|
|
13
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
14
|
-
}
|
|
15
|
-
else {
|
|
16
|
-
throw new Error("Invalid client, expected SNS | SNSClient");
|
|
17
|
-
}
|
|
18
|
-
yield page;
|
|
19
|
-
const prevToken = token;
|
|
20
|
-
token = page.NextToken;
|
|
21
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
22
|
-
}
|
|
23
|
-
return undefined;
|
|
24
|
-
}
|
|
4
|
+
export const paginateListTopics = createPaginator(SNSClient, ListTopicsCommand, "NextToken", "NextToken", "");
|