Skip to content

Commit 17e0044

Browse files
feat(api): api update
1 parent 3047e70 commit 17e0044

File tree

6 files changed

+7
-136
lines changed

6 files changed

+7
-136
lines changed

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
configured_endpoints: 5
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser%2Fcas-parser-38618cc5c938e87eeacf4893d6a6ba4e6ef7da390e6283dc7b50b484a7b97165.yml
3-
openapi_spec_hash: b9e439ecee904ded01aa34efdee88856
1+
configured_endpoints: 4
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser%2Fcas-parser-7e6397bddc220d1a59b5e2c7e7c3ff38f1a6eb174f4e383e03bc49cf78c8c44f.yml
3+
openapi_spec_hash: cb852eeb4ce89c80f4246815cbe21f72
44
config_hash: cb5d75abef6264b5d86448caf7295afa

api.md

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,3 @@ Methods:
1212
- <code title="post /v4/smart/parse">client.casParser.<a href="./src/resources/cas-parser.ts">smartParse</a>({ ...params }) -> UnifiedResponse</code>
1313

1414
# CasGenerator
15-
16-
Types:
17-
18-
- <code><a href="./src/resources/cas-generator.ts">CasGeneratorGenerateCasResponse</a></code>
19-
20-
Methods:
21-
22-
- <code title="post /v4/generate">client.casGenerator.<a href="./src/resources/cas-generator.ts">generateCas</a>({ ...params }) -> CasGeneratorGenerateCasResponse</code>

src/client.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,7 @@ import * as Errors from './core/error';
1616
import * as Uploads from './core/uploads';
1717
import * as API from './resources/index';
1818
import { APIPromise } from './core/api-promise';
19-
import {
20-
CasGenerator,
21-
CasGeneratorGenerateCasParams,
22-
CasGeneratorGenerateCasResponse,
23-
} from './resources/cas-generator';
19+
import { CasGenerator } from './resources/cas-generator';
2420
import {
2521
CasParserCamsKfintechParams,
2622
CasParserCdslParams,
@@ -747,9 +743,5 @@ export declare namespace CasParser {
747743
type CasParserSmartParseParams as CasParserSmartParseParams,
748744
};
749745

750-
export {
751-
CasGenerator as CasGenerator,
752-
type CasGeneratorGenerateCasResponse as CasGeneratorGenerateCasResponse,
753-
type CasGeneratorGenerateCasParams as CasGeneratorGenerateCasParams,
754-
};
746+
export { CasGenerator as CasGenerator };
755747
}

src/resources/cas-generator.ts

Lines changed: 1 addition & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -1,75 +1,5 @@
11
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
import { APIResource } from '../core/resource';
4-
import { APIPromise } from '../core/api-promise';
5-
import { RequestOptions } from '../internal/request-options';
64

7-
export class CasGenerator extends APIResource {
8-
/**
9-
* This endpoint generates CAS (Consolidated Account Statement) documents by
10-
* submitting a mailback request to the specified CAS authority. Currently only
11-
* supports KFintech, with plans to support CAMS, CDSL, and NSDL in the future.
12-
*
13-
* @example
14-
* ```ts
15-
* const response = await client.casGenerator.generateCas({
16-
* email: 'user@example.com',
17-
* from_date: '2023-01-01',
18-
* password: 'Abcdefghi12$',
19-
* to_date: '2023-12-31',
20-
* });
21-
* ```
22-
*/
23-
generateCas(
24-
body: CasGeneratorGenerateCasParams,
25-
options?: RequestOptions,
26-
): APIPromise<CasGeneratorGenerateCasResponse> {
27-
return this._client.post('/v4/generate', { body, ...options });
28-
}
29-
}
30-
31-
export interface CasGeneratorGenerateCasResponse {
32-
msg?: string;
33-
34-
status?: string;
35-
}
36-
37-
export interface CasGeneratorGenerateCasParams {
38-
/**
39-
* Email address to receive the CAS document
40-
*/
41-
email: string;
42-
43-
/**
44-
* Start date for the CAS period (format YYYY-MM-DD)
45-
*/
46-
from_date: string;
47-
48-
/**
49-
* Password to protect the generated CAS PDF
50-
*/
51-
password: string;
52-
53-
/**
54-
* End date for the CAS period (format YYYY-MM-DD)
55-
*/
56-
to_date: string;
57-
58-
/**
59-
* CAS authority to generate the document from (currently only kfintech is
60-
* supported)
61-
*/
62-
cas_authority?: 'kfintech' | 'cams' | 'cdsl' | 'nsdl';
63-
64-
/**
65-
* PAN number (optional for some CAS authorities)
66-
*/
67-
pan_no?: string;
68-
}
69-
70-
export declare namespace CasGenerator {
71-
export {
72-
type CasGeneratorGenerateCasResponse as CasGeneratorGenerateCasResponse,
73-
type CasGeneratorGenerateCasParams as CasGeneratorGenerateCasParams,
74-
};
75-
}
5+
export class CasGenerator extends APIResource {}

src/resources/index.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3-
export {
4-
CasGenerator,
5-
type CasGeneratorGenerateCasResponse,
6-
type CasGeneratorGenerateCasParams,
7-
} from './cas-generator';
3+
export { CasGenerator } from './cas-generator';
84
export {
95
CasParserResource,
106
type UnifiedResponse,

tests/api-resources/cas-generator.test.ts

Lines changed: 0 additions & 39 deletions
This file was deleted.

0 commit comments

Comments
 (0)