-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathkfintech.ts
More file actions
74 lines (64 loc) · 1.7 KB
/
kfintech.ts
File metadata and controls
74 lines (64 loc) · 1.7 KB
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
import { APIResource } from '../core/resource';
import { APIPromise } from '../core/api-promise';
import { RequestOptions } from '../internal/request-options';
/**
* Endpoints for generating new CAS documents via email mailback (KFintech).
*/
export class Kfintech extends APIResource {
/**
* Generate CAS via KFintech mailback. The CAS PDF will be sent to the investor's
* email.
*
* This is an async operation - the investor receives the CAS via email within a
* few minutes. For instant CAS retrieval, use CDSL Fetch (`/v4/cdsl/fetch`).
*
* @example
* ```ts
* const response = await client.kfintech.generateCas({
* email: 'user@example.com',
* from_date: '2023-01-01',
* password: 'Abcdefghi12$',
* to_date: '2023-12-31',
* });
* ```
*/
generateCas(
body: KfintechGenerateCasParams,
options?: RequestOptions,
): APIPromise<KfintechGenerateCasResponse> {
return this._client.post('/v4/kfintech/generate', { body, ...options });
}
}
export interface KfintechGenerateCasResponse {
msg?: string;
status?: string;
}
export interface KfintechGenerateCasParams {
/**
* Email address to receive the CAS document
*/
email: string;
/**
* Start date (YYYY-MM-DD)
*/
from_date: string;
/**
* Password for the PDF
*/
password: string;
/**
* End date (YYYY-MM-DD)
*/
to_date: string;
/**
* PAN number (optional)
*/
pan_no?: string;
}
export declare namespace Kfintech {
export {
type KfintechGenerateCasResponse as KfintechGenerateCasResponse,
type KfintechGenerateCasParams as KfintechGenerateCasParams,
};
}