UNPKG

10.8 kBTypeScriptView Raw
1/**
2 * Channel Access Token API
3 * This document describes Channel Access Token API.
4 *
5 * The version of the OpenAPI document: 0.0.1
6 *
7 *
8 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9 * https://openapi-generator.tech
10 * Do not edit the class manually.
11 */
12import { ChannelAccessTokenKeyIdsResponse } from "../model/channelAccessTokenKeyIdsResponse.js";
13import { IssueChannelAccessTokenResponse } from "../model/issueChannelAccessTokenResponse.js";
14import { IssueShortLivedChannelAccessTokenResponse } from "../model/issueShortLivedChannelAccessTokenResponse.js";
15import { IssueStatelessChannelAccessTokenResponse } from "../model/issueStatelessChannelAccessTokenResponse.js";
16import { VerifyChannelAccessTokenResponse } from "../model/verifyChannelAccessTokenResponse.js";
17import * as Types from "../../types.js";
18interface httpClientConfig {
19 baseURL?: string;
20}
21export declare class ChannelAccessTokenClient {
22 private httpClient;
23 constructor(config: httpClientConfig);
24 private parseHTTPResponse;
25 /**
26 * Gets all valid channel access token key IDs.
27 * @param clientAssertionType `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`
28 * @param clientAssertion A JSON Web Token (JWT) (opens new window)the client needs to create and sign with the private key.
29 *
30 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#get-all-valid-channel-access-token-key-ids-v2-1"> Documentation</a>
31 */
32 getsAllValidChannelAccessTokenKeyIds(clientAssertionType: string, clientAssertion: string): Promise<ChannelAccessTokenKeyIdsResponse>;
33 /**
34 * Gets all valid channel access token key IDs..
35 * This method includes HttpInfo object to return additional information.
36 * @param clientAssertionType `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`
37 * @param clientAssertion A JSON Web Token (JWT) (opens new window)the client needs to create and sign with the private key.
38 *
39 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#get-all-valid-channel-access-token-key-ids-v2-1"> Documentation</a>
40 */
41 getsAllValidChannelAccessTokenKeyIdsWithHttpInfo(clientAssertionType: string, clientAssertion: string): Promise<Types.ApiResponseType<ChannelAccessTokenKeyIdsResponse>>;
42 /**
43 * Issue short-lived channel access token
44 * @param grantType `client_credentials`
45 * @param clientId Channel ID.
46 * @param clientSecret Channel secret.
47 *
48 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-shortlived-channel-access-token"> Documentation</a>
49 */
50 issueChannelToken(grantType?: string, clientId?: string, clientSecret?: string): Promise<IssueShortLivedChannelAccessTokenResponse>;
51 /**
52 * Issue short-lived channel access token.
53 * This method includes HttpInfo object to return additional information.
54 * @param grantType `client_credentials`
55 * @param clientId Channel ID.
56 * @param clientSecret Channel secret.
57 *
58 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-shortlived-channel-access-token"> Documentation</a>
59 */
60 issueChannelTokenWithHttpInfo(grantType?: string, clientId?: string, clientSecret?: string): Promise<Types.ApiResponseType<IssueShortLivedChannelAccessTokenResponse>>;
61 /**
62 * Issues a channel access token that allows you to specify a desired expiration date. This method lets you use JWT assertion for authentication.
63 * @param grantType client_credentials
64 * @param clientAssertionType urn:ietf:params:oauth:client-assertion-type:jwt-bearer
65 * @param clientAssertion A JSON Web Token the client needs to create and sign with the private key of the Assertion Signing Key.
66 *
67 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-channel-access-token-v2-1"> Documentation</a>
68 */
69 issueChannelTokenByJWT(grantType?: string, clientAssertionType?: string, clientAssertion?: string): Promise<IssueChannelAccessTokenResponse>;
70 /**
71 * Issues a channel access token that allows you to specify a desired expiration date. This method lets you use JWT assertion for authentication..
72 * This method includes HttpInfo object to return additional information.
73 * @param grantType client_credentials
74 * @param clientAssertionType urn:ietf:params:oauth:client-assertion-type:jwt-bearer
75 * @param clientAssertion A JSON Web Token the client needs to create and sign with the private key of the Assertion Signing Key.
76 *
77 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-channel-access-token-v2-1"> Documentation</a>
78 */
79 issueChannelTokenByJWTWithHttpInfo(grantType?: string, clientAssertionType?: string, clientAssertion?: string): Promise<Types.ApiResponseType<IssueChannelAccessTokenResponse>>;
80 /**
81 * Issues a new stateless channel access token, which doesn\'t have max active token limit unlike the other token types. The newly issued token is only valid for 15 minutes but can not be revoked until it naturally expires.
82 * @param grantType `client_credentials`
83 * @param clientAssertionType URL-encoded value of `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`
84 * @param clientAssertion A JSON Web Token the client needs to create and sign with the private key of the Assertion Signing Key.
85 * @param clientId Channel ID.
86 * @param clientSecret Channel secret.
87 *
88 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-stateless-channel-access-token"> Documentation</a>
89 */
90 issueStatelessChannelToken(grantType?: string, clientAssertionType?: string, clientAssertion?: string, clientId?: string, clientSecret?: string): Promise<IssueStatelessChannelAccessTokenResponse>;
91 /**
92 * Issues a new stateless channel access token, which doesn\'t have max active token limit unlike the other token types. The newly issued token is only valid for 15 minutes but can not be revoked until it naturally expires. .
93 * This method includes HttpInfo object to return additional information.
94 * @param grantType `client_credentials`
95 * @param clientAssertionType URL-encoded value of `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`
96 * @param clientAssertion A JSON Web Token the client needs to create and sign with the private key of the Assertion Signing Key.
97 * @param clientId Channel ID.
98 * @param clientSecret Channel secret.
99 *
100 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#issue-stateless-channel-access-token"> Documentation</a>
101 */
102 issueStatelessChannelTokenWithHttpInfo(grantType?: string, clientAssertionType?: string, clientAssertion?: string, clientId?: string, clientSecret?: string): Promise<Types.ApiResponseType<IssueStatelessChannelAccessTokenResponse>>;
103 /**
104 * Revoke short-lived or long-lived channel access token
105 * @param accessToken Channel access token
106 *
107 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#revoke-longlived-or-shortlived-channel-access-token"> Documentation</a>
108 */
109 revokeChannelToken(accessToken?: string): Promise<Types.MessageAPIResponseBase>;
110 /**
111 * Revoke short-lived or long-lived channel access token.
112 * This method includes HttpInfo object to return additional information.
113 * @param accessToken Channel access token
114 *
115 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#revoke-longlived-or-shortlived-channel-access-token"> Documentation</a>
116 */
117 revokeChannelTokenWithHttpInfo(accessToken?: string): Promise<Types.ApiResponseType<Types.MessageAPIResponseBase>>;
118 /**
119 * Revoke channel access token v2.1
120 * @param clientId Channel ID
121 * @param clientSecret Channel Secret
122 * @param accessToken Channel access token
123 *
124 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#revoke-channel-access-token-v2-1"> Documentation</a>
125 */
126 revokeChannelTokenByJWT(clientId?: string, clientSecret?: string, accessToken?: string): Promise<Types.MessageAPIResponseBase>;
127 /**
128 * Revoke channel access token v2.1.
129 * This method includes HttpInfo object to return additional information.
130 * @param clientId Channel ID
131 * @param clientSecret Channel Secret
132 * @param accessToken Channel access token
133 *
134 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#revoke-channel-access-token-v2-1"> Documentation</a>
135 */
136 revokeChannelTokenByJWTWithHttpInfo(clientId?: string, clientSecret?: string, accessToken?: string): Promise<Types.ApiResponseType<Types.MessageAPIResponseBase>>;
137 /**
138 * Verify the validity of short-lived and long-lived channel access tokens
139 * @param accessToken A short-lived or long-lived channel access token.
140 *
141 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#verfiy-channel-access-token"> Documentation</a>
142 */
143 verifyChannelToken(accessToken?: string): Promise<VerifyChannelAccessTokenResponse>;
144 /**
145 * Verify the validity of short-lived and long-lived channel access tokens.
146 * This method includes HttpInfo object to return additional information.
147 * @param accessToken A short-lived or long-lived channel access token.
148 *
149 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#verfiy-channel-access-token"> Documentation</a>
150 */
151 verifyChannelTokenWithHttpInfo(accessToken?: string): Promise<Types.ApiResponseType<VerifyChannelAccessTokenResponse>>;
152 /**
153 * You can verify whether a Channel access token with a user-specified expiration (Channel Access Token v2.1) is valid.
154 * @param accessToken Channel access token with a user-specified expiration (Channel Access Token v2.1).
155 *
156 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#verfiy-channel-access-token-v2-1"> Documentation</a>
157 */
158 verifyChannelTokenByJWT(accessToken: string): Promise<VerifyChannelAccessTokenResponse>;
159 /**
160 * You can verify whether a Channel access token with a user-specified expiration (Channel Access Token v2.1) is valid..
161 * This method includes HttpInfo object to return additional information.
162 * @param accessToken Channel access token with a user-specified expiration (Channel Access Token v2.1).
163 *
164 * @see <a href="https://developers.line.biz/en/reference/messaging-api/#verfiy-channel-access-token-v2-1"> Documentation</a>
165 */
166 verifyChannelTokenByJWTWithHttpInfo(accessToken: string): Promise<Types.ApiResponseType<VerifyChannelAccessTokenResponse>>;
167}
168export {};
169//# sourceMappingURL=channelAccessTokenClient.d.ts.map
\No newline at end of file