forked from stripe/stripe-node
-
Notifications
You must be signed in to change notification settings - Fork 0
/
AccountLinksResource.d.ts
53 lines (44 loc) · 1.94 KB
/
AccountLinksResource.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
// File generated from our OpenAPI spec
declare module 'stripe' {
namespace Stripe {
interface AccountLinkCreateParams {
/**
* The identifier of the account to create an account link for.
*/
account: string;
/**
* The type of account link the user is requesting. Possible values are `account_onboarding` or `account_update`.
*/
type: AccountLinkCreateParams.Type;
/**
* Which information the platform needs to collect from the user. One of `currently_due` or `eventually_due`. Default is `currently_due`.
*/
collect?: AccountLinkCreateParams.Collect;
/**
* Specifies which fields in the response should be expanded.
*/
expand?: Array<string>;
/**
* The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
*/
refresh_url?: string;
/**
* The URL that the user will be redirected to upon leaving or completing the linked flow.
*/
return_url?: string;
}
namespace AccountLinkCreateParams {
type Collect = 'currently_due' | 'eventually_due';
type Type = 'account_onboarding' | 'account_update';
}
class AccountLinksResource {
/**
* Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.
*/
create(
params: AccountLinkCreateParams,
options?: RequestOptions
): Promise<Stripe.Response<Stripe.AccountLink>>;
}
}
}