@rundit-sdk/embed 0.0.1
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/AGENTS.md +68 -0
- package/README.md +123 -0
- package/ai-manifest.json +200 -0
- package/dist/index.d.ts +234 -0
- package/dist/index.js +326 -0
- package/openapi.json +755 -0
- package/package.json +25 -0
package/AGENTS.md
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# AI Guide for @rundit-sdk/embed
|
|
2
|
+
|
|
3
|
+
This package is generated for agentic and human consumers.
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
## Initialization
|
|
8
|
+
|
|
9
|
+
```ts
|
|
10
|
+
import { createEmbedClient, routeManifest } from '@rundit-sdk/embed'
|
|
11
|
+
|
|
12
|
+
const client = createEmbedClient({
|
|
13
|
+
baseUrl: 'https://test.rundit.com/api/v1/sdk',
|
|
14
|
+
token: '<embed token>',
|
|
15
|
+
})
|
|
16
|
+
|
|
17
|
+
console.log(routeManifest)
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Guidance
|
|
21
|
+
|
|
22
|
+
- Prefer namespace methods on the client instead of constructing URLs manually
|
|
23
|
+
- Use `routeManifest` or `ai-manifest.json` to discover available calls programmatically
|
|
24
|
+
- Pass required path ids as strings or numbers
|
|
25
|
+
- Positions endpoints require a `currency` query value
|
|
26
|
+
- Response ids are strings; preserve them as returned when passing them between calls
|
|
27
|
+
|
|
28
|
+
## companies
|
|
29
|
+
|
|
30
|
+
- companies.getOne: Get one company available to the SDK consumer
|
|
31
|
+
- Call: `client.companies.getOne('123')`
|
|
32
|
+
- Returns: `CompaniesGetOneResponse`
|
|
33
|
+
- Params: path: id (string)
|
|
34
|
+
- companies.getAll: List companies available to the SDK consumer
|
|
35
|
+
- Call: `client.companies.getAll()`
|
|
36
|
+
- Returns: `CompaniesGetAllResponse`
|
|
37
|
+
|
|
38
|
+
## companyGroups
|
|
39
|
+
|
|
40
|
+
- companyGroups.getAll: List company groups available to the SDK consumer
|
|
41
|
+
- Call: `client.companyGroups.getAll()`
|
|
42
|
+
- Returns: `CompanyGroupsGetAllResponse`
|
|
43
|
+
- companyGroups.getOne: Get one company group available to the SDK consumer
|
|
44
|
+
- Call: `client.companyGroups.getOne('123')`
|
|
45
|
+
- Returns: `CompanyGroupsGetOneResponse`
|
|
46
|
+
- Params: path: id (string)
|
|
47
|
+
|
|
48
|
+
## positions
|
|
49
|
+
|
|
50
|
+
- positions.getCompanyPositions: Get positions for one company
|
|
51
|
+
- Call: `client.positions.getCompanyPositions('123', { currency: 'USD' })`
|
|
52
|
+
- Returns: `PositionsGetCompanyPositionsResponse`
|
|
53
|
+
- Params: path: id (string); query: companyGroupId? (number), currency (string), date? (string)
|
|
54
|
+
- positions.getPortfolioPositions: Get portfolio positions
|
|
55
|
+
- Call: `client.positions.getPortfolioPositions({ currency: 'USD' })`
|
|
56
|
+
- Returns: `PositionsGetPortfolioPositionsResponse`
|
|
57
|
+
- Params: query: companyGroupIds? (number[]), currency (string), date? (string)
|
|
58
|
+
|
|
59
|
+
## transactions
|
|
60
|
+
|
|
61
|
+
- transactions.getCompanyTransactions: Get transactions for one company
|
|
62
|
+
- Call: `client.transactions.getCompanyTransactions('123', { companyGroupIds: [123] })`
|
|
63
|
+
- Returns: `TransactionsGetCompanyTransactionsResponse`
|
|
64
|
+
- Params: path: id (string); query: companyGroupIds? (number[])
|
|
65
|
+
- transactions.getTransactions: Get transactions for multiple companies
|
|
66
|
+
- Call: `client.transactions.getTransactions({ companyGroupIds: [123] })`
|
|
67
|
+
- Returns: `TransactionsGetTransactionsResponse`
|
|
68
|
+
- Params: query: companyGroupIds? (number[]), companyIds? (number[])
|
package/README.md
ADDED
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# @rundit-sdk/embed
|
|
2
|
+
|
|
3
|
+
Public Rundit embed SDK for iframe and embedded module consumers.
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install @rundit-sdk/embed
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Usage
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
import { createEmbedClient } from '@rundit-sdk/embed'
|
|
17
|
+
|
|
18
|
+
const client = createEmbedClient({
|
|
19
|
+
baseUrl: 'https://test.rundit.com/api/v1/sdk',
|
|
20
|
+
token: '<embed token>',
|
|
21
|
+
})
|
|
22
|
+
|
|
23
|
+
await client.companies.getOne('123')
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## AI Quickstart
|
|
27
|
+
|
|
28
|
+
- Use namespace methods such as `client.companies.getAll()` or `client.positions.getPortfolioPositions({ currency: 'USD' })`
|
|
29
|
+
- Inspect `routeManifest` at runtime for a machine-readable map of method paths, parameters, and response types
|
|
30
|
+
- Read `AGENTS.md` or `ai-manifest.json` in this package for AI-focused usage guidance
|
|
31
|
+
- Response DTO identifiers are returned as strings even when the underlying backend ids are numeric
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
## Methods
|
|
35
|
+
|
|
36
|
+
## companies
|
|
37
|
+
|
|
38
|
+
### `companies.getOne`
|
|
39
|
+
|
|
40
|
+
Get one company available to the SDK consumer
|
|
41
|
+
|
|
42
|
+
- Call: `client.companies.getOne('123')`
|
|
43
|
+
- HTTP: `GET /companies/:id`
|
|
44
|
+
- Returns: `CompaniesGetOneResponse`
|
|
45
|
+
- Params: path: id (string)
|
|
46
|
+
|
|
47
|
+
### `companies.getAll`
|
|
48
|
+
|
|
49
|
+
List companies available to the SDK consumer
|
|
50
|
+
|
|
51
|
+
- Call: `client.companies.getAll()`
|
|
52
|
+
- HTTP: `GET /companies`
|
|
53
|
+
- Returns: `CompaniesGetAllResponse`
|
|
54
|
+
|
|
55
|
+
## companyGroups
|
|
56
|
+
|
|
57
|
+
### `companyGroups.getAll`
|
|
58
|
+
|
|
59
|
+
List company groups available to the SDK consumer
|
|
60
|
+
|
|
61
|
+
- Call: `client.companyGroups.getAll()`
|
|
62
|
+
- HTTP: `GET /company-groups`
|
|
63
|
+
- Returns: `CompanyGroupsGetAllResponse`
|
|
64
|
+
|
|
65
|
+
### `companyGroups.getOne`
|
|
66
|
+
|
|
67
|
+
Get one company group available to the SDK consumer
|
|
68
|
+
|
|
69
|
+
- Call: `client.companyGroups.getOne('123')`
|
|
70
|
+
- HTTP: `GET /company-groups/:id`
|
|
71
|
+
- Returns: `CompanyGroupsGetOneResponse`
|
|
72
|
+
- Params: path: id (string)
|
|
73
|
+
|
|
74
|
+
## positions
|
|
75
|
+
|
|
76
|
+
### `positions.getCompanyPositions`
|
|
77
|
+
|
|
78
|
+
Get positions for one company
|
|
79
|
+
|
|
80
|
+
- Call: `client.positions.getCompanyPositions('123', { currency: 'USD' })`
|
|
81
|
+
- HTTP: `GET /positions/companies/:id`
|
|
82
|
+
- Returns: `PositionsGetCompanyPositionsResponse`
|
|
83
|
+
- Params: path: id (string); query: companyGroupId? (number), currency (string), date? (string)
|
|
84
|
+
|
|
85
|
+
### `positions.getPortfolioPositions`
|
|
86
|
+
|
|
87
|
+
Get portfolio positions
|
|
88
|
+
|
|
89
|
+
- Call: `client.positions.getPortfolioPositions({ currency: 'USD' })`
|
|
90
|
+
- HTTP: `GET /positions/portfolio`
|
|
91
|
+
- Returns: `PositionsGetPortfolioPositionsResponse`
|
|
92
|
+
- Params: query: companyGroupIds? (number[]), currency (string), date? (string)
|
|
93
|
+
|
|
94
|
+
## transactions
|
|
95
|
+
|
|
96
|
+
### `transactions.getCompanyTransactions`
|
|
97
|
+
|
|
98
|
+
Get transactions for one company
|
|
99
|
+
|
|
100
|
+
- Call: `client.transactions.getCompanyTransactions('123', { companyGroupIds: [123] })`
|
|
101
|
+
- HTTP: `GET /transactions/companies/:id`
|
|
102
|
+
- Returns: `TransactionsGetCompanyTransactionsResponse`
|
|
103
|
+
- Params: path: id (string); query: companyGroupIds? (number[])
|
|
104
|
+
|
|
105
|
+
### `transactions.getTransactions`
|
|
106
|
+
|
|
107
|
+
Get transactions for multiple companies
|
|
108
|
+
|
|
109
|
+
- Call: `client.transactions.getTransactions({ companyGroupIds: [123] })`
|
|
110
|
+
- HTTP: `GET /transactions`
|
|
111
|
+
- Returns: `TransactionsGetTransactionsResponse`
|
|
112
|
+
- Params: query: companyGroupIds? (number[]), companyIds? (number[])
|
|
113
|
+
|
|
114
|
+
## TypeScript
|
|
115
|
+
|
|
116
|
+
- This package ships generated `.d.ts` files
|
|
117
|
+
- Public DTOs, response aliases, and query parameter types are generated from `sdk-packages/openapi/sdk.openapi.json`
|
|
118
|
+
- Generated methods and query types include JSDoc summaries for editor and agent consumption
|
|
119
|
+
|
|
120
|
+
## Notes
|
|
121
|
+
|
|
122
|
+
- This package is generated from `sdk-packages/openapi/sdk.openapi.json`
|
|
123
|
+
- Do not edit files under `dist/` manually
|
package/ai-manifest.json
ADDED
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
{
|
|
2
|
+
"packageName": "@rundit-sdk/embed",
|
|
3
|
+
"description": "Public Rundit embed SDK for iframe and embedded module consumers.",
|
|
4
|
+
"maturity": "active",
|
|
5
|
+
"placeholderNotice": null,
|
|
6
|
+
"factoryName": "createEmbedClient",
|
|
7
|
+
"initialization": {
|
|
8
|
+
"baseUrl": "https://test.rundit.com/api/v1/sdk",
|
|
9
|
+
"authOption": "token",
|
|
10
|
+
"authLabel": "embed token"
|
|
11
|
+
},
|
|
12
|
+
"guidance": {
|
|
13
|
+
"responseIdsAreStrings": true,
|
|
14
|
+
"runtimeManifestExport": "routeManifest",
|
|
15
|
+
"notes": [
|
|
16
|
+
"Use namespace methods instead of manual fetch calls",
|
|
17
|
+
"Positions endpoints require currency"
|
|
18
|
+
]
|
|
19
|
+
},
|
|
20
|
+
"namespaces": {
|
|
21
|
+
"companies": [
|
|
22
|
+
{
|
|
23
|
+
"operation": "getOne",
|
|
24
|
+
"summary": "Get one company available to the SDK consumer",
|
|
25
|
+
"description": null,
|
|
26
|
+
"method": "GET",
|
|
27
|
+
"path": "/companies/:id",
|
|
28
|
+
"exampleCall": "client.companies.getOne('123')",
|
|
29
|
+
"responseType": "CompaniesGetOneResponse",
|
|
30
|
+
"pathParams": [
|
|
31
|
+
{
|
|
32
|
+
"name": "id",
|
|
33
|
+
"type": "string",
|
|
34
|
+
"description": "Company identifier"
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"queryParams": []
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"operation": "getAll",
|
|
41
|
+
"summary": "List companies available to the SDK consumer",
|
|
42
|
+
"description": null,
|
|
43
|
+
"method": "GET",
|
|
44
|
+
"path": "/companies",
|
|
45
|
+
"exampleCall": "client.companies.getAll()",
|
|
46
|
+
"responseType": "CompaniesGetAllResponse",
|
|
47
|
+
"pathParams": [],
|
|
48
|
+
"queryParams": []
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
"companyGroups": [
|
|
52
|
+
{
|
|
53
|
+
"operation": "getAll",
|
|
54
|
+
"summary": "List company groups available to the SDK consumer",
|
|
55
|
+
"description": null,
|
|
56
|
+
"method": "GET",
|
|
57
|
+
"path": "/company-groups",
|
|
58
|
+
"exampleCall": "client.companyGroups.getAll()",
|
|
59
|
+
"responseType": "CompanyGroupsGetAllResponse",
|
|
60
|
+
"pathParams": [],
|
|
61
|
+
"queryParams": []
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"operation": "getOne",
|
|
65
|
+
"summary": "Get one company group available to the SDK consumer",
|
|
66
|
+
"description": null,
|
|
67
|
+
"method": "GET",
|
|
68
|
+
"path": "/company-groups/:id",
|
|
69
|
+
"exampleCall": "client.companyGroups.getOne('123')",
|
|
70
|
+
"responseType": "CompanyGroupsGetOneResponse",
|
|
71
|
+
"pathParams": [
|
|
72
|
+
{
|
|
73
|
+
"name": "id",
|
|
74
|
+
"type": "string",
|
|
75
|
+
"description": "Company group identifier"
|
|
76
|
+
}
|
|
77
|
+
],
|
|
78
|
+
"queryParams": []
|
|
79
|
+
}
|
|
80
|
+
],
|
|
81
|
+
"positions": [
|
|
82
|
+
{
|
|
83
|
+
"operation": "getCompanyPositions",
|
|
84
|
+
"summary": "Get positions for one company",
|
|
85
|
+
"description": null,
|
|
86
|
+
"method": "GET",
|
|
87
|
+
"path": "/positions/companies/:id",
|
|
88
|
+
"exampleCall": "client.positions.getCompanyPositions('123', { currency: 'USD' })",
|
|
89
|
+
"responseType": "PositionsGetCompanyPositionsResponse",
|
|
90
|
+
"pathParams": [
|
|
91
|
+
{
|
|
92
|
+
"name": "id",
|
|
93
|
+
"type": "string",
|
|
94
|
+
"description": "Company identifier"
|
|
95
|
+
}
|
|
96
|
+
],
|
|
97
|
+
"queryParams": [
|
|
98
|
+
{
|
|
99
|
+
"name": "companyGroupId",
|
|
100
|
+
"required": false,
|
|
101
|
+
"type": "number",
|
|
102
|
+
"description": "Optional company group identifier to filter by"
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
"name": "currency",
|
|
106
|
+
"required": true,
|
|
107
|
+
"type": "string",
|
|
108
|
+
"description": "Reporting currency code"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"name": "date",
|
|
112
|
+
"required": false,
|
|
113
|
+
"type": "string",
|
|
114
|
+
"description": "Optional summary date in ISO format"
|
|
115
|
+
}
|
|
116
|
+
]
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"operation": "getPortfolioPositions",
|
|
120
|
+
"summary": "Get portfolio positions",
|
|
121
|
+
"description": null,
|
|
122
|
+
"method": "GET",
|
|
123
|
+
"path": "/positions/portfolio",
|
|
124
|
+
"exampleCall": "client.positions.getPortfolioPositions({ currency: 'USD' })",
|
|
125
|
+
"responseType": "PositionsGetPortfolioPositionsResponse",
|
|
126
|
+
"pathParams": [],
|
|
127
|
+
"queryParams": [
|
|
128
|
+
{
|
|
129
|
+
"name": "companyGroupIds",
|
|
130
|
+
"required": false,
|
|
131
|
+
"type": "number[]",
|
|
132
|
+
"description": "Optional list of company group identifiers to filter the portfolio positions"
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
"name": "currency",
|
|
136
|
+
"required": true,
|
|
137
|
+
"type": "string",
|
|
138
|
+
"description": "Reporting currency code"
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
"name": "date",
|
|
142
|
+
"required": false,
|
|
143
|
+
"type": "string",
|
|
144
|
+
"description": "Optional summary date in ISO format"
|
|
145
|
+
}
|
|
146
|
+
]
|
|
147
|
+
}
|
|
148
|
+
],
|
|
149
|
+
"transactions": [
|
|
150
|
+
{
|
|
151
|
+
"operation": "getCompanyTransactions",
|
|
152
|
+
"summary": "Get transactions for one company",
|
|
153
|
+
"description": null,
|
|
154
|
+
"method": "GET",
|
|
155
|
+
"path": "/transactions/companies/:id",
|
|
156
|
+
"exampleCall": "client.transactions.getCompanyTransactions('123', { companyGroupIds: [123] })",
|
|
157
|
+
"responseType": "TransactionsGetCompanyTransactionsResponse",
|
|
158
|
+
"pathParams": [
|
|
159
|
+
{
|
|
160
|
+
"name": "id",
|
|
161
|
+
"type": "string",
|
|
162
|
+
"description": "Company identifier"
|
|
163
|
+
}
|
|
164
|
+
],
|
|
165
|
+
"queryParams": [
|
|
166
|
+
{
|
|
167
|
+
"name": "companyGroupIds",
|
|
168
|
+
"required": false,
|
|
169
|
+
"type": "number[]",
|
|
170
|
+
"description": "Optional company group identifiers to filter transactions by"
|
|
171
|
+
}
|
|
172
|
+
]
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
"operation": "getTransactions",
|
|
176
|
+
"summary": "Get transactions for multiple companies",
|
|
177
|
+
"description": null,
|
|
178
|
+
"method": "GET",
|
|
179
|
+
"path": "/transactions",
|
|
180
|
+
"exampleCall": "client.transactions.getTransactions({ companyGroupIds: [123] })",
|
|
181
|
+
"responseType": "TransactionsGetTransactionsResponse",
|
|
182
|
+
"pathParams": [],
|
|
183
|
+
"queryParams": [
|
|
184
|
+
{
|
|
185
|
+
"name": "companyGroupIds",
|
|
186
|
+
"required": false,
|
|
187
|
+
"type": "number[]",
|
|
188
|
+
"description": "Optional company group identifiers to filter transactions by"
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"name": "companyIds",
|
|
192
|
+
"required": false,
|
|
193
|
+
"type": "number[]",
|
|
194
|
+
"description": "Optional company identifiers to filter transactions by"
|
|
195
|
+
}
|
|
196
|
+
]
|
|
197
|
+
}
|
|
198
|
+
]
|
|
199
|
+
}
|
|
200
|
+
}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
export type PathParam = string | number
|
|
2
|
+
|
|
3
|
+
export interface RequestOptions {
|
|
4
|
+
signal?: AbortSignal
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export interface RunditSdkErrorDetails {
|
|
8
|
+
status: number
|
|
9
|
+
body: unknown
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export declare class RunditSdkError extends Error {
|
|
13
|
+
status: number
|
|
14
|
+
body: unknown
|
|
15
|
+
constructor(message: string, details: RunditSdkErrorDetails)
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface CreateEmbedClientOptions {
|
|
19
|
+
baseUrl: string
|
|
20
|
+
token: string
|
|
21
|
+
fetch?: typeof fetch
|
|
22
|
+
headers?: Record<string, string>
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export interface SdkCompanyDto {
|
|
26
|
+
id: string
|
|
27
|
+
name: string
|
|
28
|
+
type?: string
|
|
29
|
+
legalName?: string
|
|
30
|
+
status?: string
|
|
31
|
+
websiteUrl?: string
|
|
32
|
+
companyGroupIds?: string[]
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export interface SdkCompanyGroupDto {
|
|
36
|
+
id: string
|
|
37
|
+
name: string
|
|
38
|
+
currency?: string
|
|
39
|
+
companyIds?: string[]
|
|
40
|
+
companies?: SdkCompanyDto[]
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface SdkCompanyReferenceDto {
|
|
44
|
+
id: string
|
|
45
|
+
name: string
|
|
46
|
+
type?: string
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface SdkCompanyGroupReferenceDto {
|
|
50
|
+
id: string
|
|
51
|
+
name: string
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export interface SdkPositionDto {
|
|
55
|
+
id: string
|
|
56
|
+
companyId: string
|
|
57
|
+
companyGroupId?: string
|
|
58
|
+
company?: SdkCompanyReferenceDto
|
|
59
|
+
companyGroup?: SdkCompanyGroupReferenceDto
|
|
60
|
+
units: number
|
|
61
|
+
fairValue?: number
|
|
62
|
+
ownership?: number
|
|
63
|
+
invested?: number
|
|
64
|
+
realized?: number
|
|
65
|
+
multiple?: number
|
|
66
|
+
investmentStatus?: string
|
|
67
|
+
currency: string
|
|
68
|
+
date: string
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export interface SdkTransactionDto {
|
|
72
|
+
id: string
|
|
73
|
+
companyId: string
|
|
74
|
+
companyGroupId?: string
|
|
75
|
+
company?: SdkCompanyReferenceDto
|
|
76
|
+
companyGroup?: SdkCompanyGroupReferenceDto
|
|
77
|
+
type: string
|
|
78
|
+
name?: string
|
|
79
|
+
date: string
|
|
80
|
+
amount?: number
|
|
81
|
+
fairValue?: number
|
|
82
|
+
currency?: string
|
|
83
|
+
children?: SdkTransactionDto[]
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export type CompaniesGetOneResponse = SdkCompanyDto
|
|
87
|
+
|
|
88
|
+
export type CompaniesGetAllResponse = SdkCompanyDto[]
|
|
89
|
+
|
|
90
|
+
export type CompanyGroupsGetAllResponse = SdkCompanyGroupDto[]
|
|
91
|
+
|
|
92
|
+
export type CompanyGroupsGetOneResponse = SdkCompanyGroupDto
|
|
93
|
+
|
|
94
|
+
export type PositionsGetCompanyPositionsResponse = SdkPositionDto[]
|
|
95
|
+
|
|
96
|
+
export type PositionsGetPortfolioPositionsResponse = SdkPositionDto[]
|
|
97
|
+
|
|
98
|
+
export type TransactionsGetCompanyTransactionsResponse = SdkTransactionDto[]
|
|
99
|
+
|
|
100
|
+
export type TransactionsGetTransactionsResponse = SdkTransactionDto[]
|
|
101
|
+
|
|
102
|
+
export interface PositionsGetCompanyPositionsQuery {
|
|
103
|
+
/**
|
|
104
|
+
* Optional company group identifier to filter by
|
|
105
|
+
*/
|
|
106
|
+
companyGroupId?: number
|
|
107
|
+
/**
|
|
108
|
+
* Reporting currency code
|
|
109
|
+
*/
|
|
110
|
+
currency: string
|
|
111
|
+
/**
|
|
112
|
+
* Optional summary date in ISO format
|
|
113
|
+
*/
|
|
114
|
+
date?: string
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export interface PositionsGetPortfolioPositionsQuery {
|
|
118
|
+
/**
|
|
119
|
+
* Optional list of company group identifiers to filter the portfolio positions
|
|
120
|
+
*/
|
|
121
|
+
companyGroupIds?: number[]
|
|
122
|
+
/**
|
|
123
|
+
* Reporting currency code
|
|
124
|
+
*/
|
|
125
|
+
currency: string
|
|
126
|
+
/**
|
|
127
|
+
* Optional summary date in ISO format
|
|
128
|
+
*/
|
|
129
|
+
date?: string
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export interface TransactionsGetCompanyTransactionsQuery {
|
|
133
|
+
/**
|
|
134
|
+
* Optional company group identifiers to filter transactions by
|
|
135
|
+
*/
|
|
136
|
+
companyGroupIds?: number[]
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export interface TransactionsGetTransactionsQuery {
|
|
140
|
+
/**
|
|
141
|
+
* Optional company group identifiers to filter transactions by
|
|
142
|
+
*/
|
|
143
|
+
companyGroupIds?: number[]
|
|
144
|
+
/**
|
|
145
|
+
* Optional company identifiers to filter transactions by
|
|
146
|
+
*/
|
|
147
|
+
companyIds?: number[]
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export interface CompaniesNamespace {
|
|
151
|
+
/**
|
|
152
|
+
* Get one company available to the SDK consumer
|
|
153
|
+
* Parameters: path: id (string)
|
|
154
|
+
* Returns: CompaniesGetOneResponse
|
|
155
|
+
*/
|
|
156
|
+
getOne(id: string, init?: RequestOptions): Promise<CompaniesGetOneResponse>
|
|
157
|
+
/**
|
|
158
|
+
* List companies available to the SDK consumer
|
|
159
|
+
* Returns: CompaniesGetAllResponse
|
|
160
|
+
*/
|
|
161
|
+
getAll(init?: RequestOptions): Promise<CompaniesGetAllResponse>
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
export interface CompanyGroupsNamespace {
|
|
165
|
+
/**
|
|
166
|
+
* List company groups available to the SDK consumer
|
|
167
|
+
* Returns: CompanyGroupsGetAllResponse
|
|
168
|
+
*/
|
|
169
|
+
getAll(init?: RequestOptions): Promise<CompanyGroupsGetAllResponse>
|
|
170
|
+
/**
|
|
171
|
+
* Get one company group available to the SDK consumer
|
|
172
|
+
* Parameters: path: id (string)
|
|
173
|
+
* Returns: CompanyGroupsGetOneResponse
|
|
174
|
+
*/
|
|
175
|
+
getOne(id: string, init?: RequestOptions): Promise<CompanyGroupsGetOneResponse>
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
export interface PositionsNamespace {
|
|
179
|
+
/**
|
|
180
|
+
* Get positions for one company
|
|
181
|
+
* Parameters: path: id (string); query: companyGroupId? (number), currency (string), date? (string)
|
|
182
|
+
* Returns: PositionsGetCompanyPositionsResponse
|
|
183
|
+
*/
|
|
184
|
+
getCompanyPositions(id: string, query?: PositionsGetCompanyPositionsQuery, init?: RequestOptions): Promise<PositionsGetCompanyPositionsResponse>
|
|
185
|
+
/**
|
|
186
|
+
* Get portfolio positions
|
|
187
|
+
* Parameters: query: companyGroupIds? (number[]), currency (string), date? (string)
|
|
188
|
+
* Returns: PositionsGetPortfolioPositionsResponse
|
|
189
|
+
*/
|
|
190
|
+
getPortfolioPositions(query?: PositionsGetPortfolioPositionsQuery, init?: RequestOptions): Promise<PositionsGetPortfolioPositionsResponse>
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
export interface TransactionsNamespace {
|
|
194
|
+
/**
|
|
195
|
+
* Get transactions for one company
|
|
196
|
+
* Parameters: path: id (string); query: companyGroupIds? (number[])
|
|
197
|
+
* Returns: TransactionsGetCompanyTransactionsResponse
|
|
198
|
+
*/
|
|
199
|
+
getCompanyTransactions(id: string, query?: TransactionsGetCompanyTransactionsQuery, init?: RequestOptions): Promise<TransactionsGetCompanyTransactionsResponse>
|
|
200
|
+
/**
|
|
201
|
+
* Get transactions for multiple companies
|
|
202
|
+
* Parameters: query: companyGroupIds? (number[]), companyIds? (number[])
|
|
203
|
+
* Returns: TransactionsGetTransactionsResponse
|
|
204
|
+
*/
|
|
205
|
+
getTransactions(query?: TransactionsGetTransactionsQuery, init?: RequestOptions): Promise<TransactionsGetTransactionsResponse>
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export interface EmbedClient {
|
|
209
|
+
companies: CompaniesNamespace
|
|
210
|
+
companyGroups: CompanyGroupsNamespace
|
|
211
|
+
positions: PositionsNamespace
|
|
212
|
+
transactions: TransactionsNamespace
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
export declare function createEmbedClient(options: CreateEmbedClientOptions): EmbedClient
|
|
216
|
+
|
|
217
|
+
export declare const routeManifest: {
|
|
218
|
+
companies: {
|
|
219
|
+
getOne: { method: "GET"; path: "/companies/:id"; summary: "Get one company available to the SDK consumer"; description: null; exampleCall: "client.companies.getOne('123')"; responseType: "CompaniesGetOneResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
220
|
+
getAll: { method: "GET"; path: "/companies"; summary: "List companies available to the SDK consumer"; description: null; exampleCall: "client.companies.getAll()"; responseType: "CompaniesGetAllResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
221
|
+
}
|
|
222
|
+
companyGroups: {
|
|
223
|
+
getAll: { method: "GET"; path: "/company-groups"; summary: "List company groups available to the SDK consumer"; description: null; exampleCall: "client.companyGroups.getAll()"; responseType: "CompanyGroupsGetAllResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
224
|
+
getOne: { method: "GET"; path: "/company-groups/:id"; summary: "Get one company group available to the SDK consumer"; description: null; exampleCall: "client.companyGroups.getOne('123')"; responseType: "CompanyGroupsGetOneResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
225
|
+
}
|
|
226
|
+
positions: {
|
|
227
|
+
getCompanyPositions: { method: "GET"; path: "/positions/companies/:id"; summary: "Get positions for one company"; description: null; exampleCall: "client.positions.getCompanyPositions('123', { currency: 'USD' })"; responseType: "PositionsGetCompanyPositionsResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
228
|
+
getPortfolioPositions: { method: "GET"; path: "/positions/portfolio"; summary: "Get portfolio positions"; description: null; exampleCall: "client.positions.getPortfolioPositions({ currency: 'USD' })"; responseType: "PositionsGetPortfolioPositionsResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
229
|
+
}
|
|
230
|
+
transactions: {
|
|
231
|
+
getCompanyTransactions: { method: "GET"; path: "/transactions/companies/:id"; summary: "Get transactions for one company"; description: null; exampleCall: "client.transactions.getCompanyTransactions('123', { companyGroupIds: [123] })"; responseType: "TransactionsGetCompanyTransactionsResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
232
|
+
getTransactions: { method: "GET"; path: "/transactions"; summary: "Get transactions for multiple companies"; description: null; exampleCall: "client.transactions.getTransactions({ companyGroupIds: [123] })"; responseType: "TransactionsGetTransactionsResponse"; pathParams: { name: string; type: string; description: string | null }[]; queryParams: { name: string; type: string; required: boolean; description: string | null }[] }
|
|
233
|
+
}
|
|
234
|
+
}
|