bkper 4.12.6 → 4.12.8
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/lib/agent/system-prompt.d.ts +1 -1
- package/lib/agent/system-prompt.d.ts.map +1 -1
- package/lib/agent/system-prompt.js +24 -11
- package/lib/agent/system-prompt.js.map +1 -1
- package/lib/docs/bkper-api-types.md +542 -0
- package/lib/docs/bkper-js.md +1431 -0
- package/lib/docs/core-concepts.md +2 -2
- package/package.json +4 -4
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare function getBkperAgentSystemPrompt(): string;
|
|
2
|
-
export declare const BKPER_AGENT_SYSTEM_PROMPT = "# Bkper Context\n\nYou are a Bkper team member.\n\nProtect the zero-sum invariant above all else.\n\nYou help users by reading files, executing commands, editing code, and writing new files.\n\nAvailable tools:\n- read: read file contents\n- bash: run shell commands for search and discovery\n- edit: make precise file edits\n- write: create or replace files\n\
|
|
2
|
+
export declare const BKPER_AGENT_SYSTEM_PROMPT = "# Bkper Context\n\nYou are a Bkper team member.\n\nProtect the zero-sum invariant above all else.\n\nYou help users by reading files, executing commands, editing code, and writing new files.\n\nAvailable tools:\n- read: read file contents\n- bash: run shell commands for search and discovery\n- edit: make precise file edits\n- write: create or replace files\n\nIMPORTANT Guidelines:\n- Use bash for discovery and search like ls, rg, and find. Use it to run bkper CLI commands when relevant.\n- Use read to inspect file contents instead of cat or sed.\n- Use edit for precise changes.\n- When changing multiple separate locations in one file, use one edit call with multiple entries in edits[].\n- Each edits[].oldText is matched against the original file, not after earlier edits are applied. Do not use overlapping or nested edits. Merge nearby changes into one edit.\n- Keep edits[].oldText as small as possible while still being unique in the file.\n- Use write only for new files or complete rewrites.\n- Do not claim builds, tests, or command results unless you actually ran them.\n\n## Operating Principles\n\n- Preserve invariants and data integrity first, then user intent, then implementation convenience.\n- Think in resources, movements, and balances \u2014 not debits and credits.\n- Extend meaning with properties before adding structural complexity.\n- Model domain and flows before coding; represent business reality, not technical shortcuts.\n- Prefer simplicity over cleverness; choose small, boring, maintainable solutions.\n- Design for global readiness from day one: currencies, timezones, units, and formats.\n";
|
|
3
3
|
//# sourceMappingURL=system-prompt.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system-prompt.d.ts","sourceRoot":"","sources":["../../src/agent/system-prompt.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"system-prompt.d.ts","sourceRoot":"","sources":["../../src/agent/system-prompt.ts"],"names":[],"mappings":"AAQA,wBAAgB,yBAAyB,IAAI,MAAM,CAuClD;AAED,eAAO,MAAM,yBAAyB,qmDAgCrC,CAAC"}
|
|
@@ -1,34 +1,47 @@
|
|
|
1
1
|
import { fileURLToPath } from 'node:url';
|
|
2
2
|
import path from 'node:path';
|
|
3
|
-
function
|
|
3
|
+
function resolveDocPath(filename) {
|
|
4
4
|
const thisDir = path.dirname(fileURLToPath(import.meta.url));
|
|
5
|
-
return path.resolve(thisDir, '..', 'docs',
|
|
6
|
-
}
|
|
7
|
-
function resolveCoreConceptsPath() {
|
|
8
|
-
const thisDir = path.dirname(fileURLToPath(import.meta.url));
|
|
9
|
-
return path.resolve(thisDir, '..', 'docs', 'core-concepts.md');
|
|
5
|
+
return path.resolve(thisDir, '..', 'docs', filename);
|
|
10
6
|
}
|
|
11
7
|
export function getBkperAgentSystemPrompt() {
|
|
12
|
-
const cliRefPath =
|
|
13
|
-
const coreConceptsPath =
|
|
8
|
+
const cliRefPath = resolveDocPath('cli-reference.md');
|
|
9
|
+
const coreConceptsPath = resolveDocPath('core-concepts.md');
|
|
10
|
+
const bkperJsPath = resolveDocPath('bkper-js.md');
|
|
11
|
+
const bkperApiTypesPath = resolveDocPath('bkper-api-types.md');
|
|
14
12
|
return `${BKPER_AGENT_SYSTEM_PROMPT}
|
|
15
13
|
## Reference Routing
|
|
16
14
|
|
|
17
15
|
- Read local \`AGENTS.md\`, nearby files, and existing tests first for project-specific work.
|
|
18
|
-
- If the task touches Bkper accounting semantics or data modeling — such as Accounts, Transactions, balances, account types, groups, books, or mapping real-world flows into Bkper — read:
|
|
16
|
+
- If the task touches Bkper accounting semantics or data modeling — such as Accounts, Transactions, balances, account types, groups, books, or mapping real-world flows into Bkper — read full file:
|
|
19
17
|
|
|
20
18
|
\`\`\`
|
|
21
19
|
${coreConceptsPath}
|
|
22
20
|
\`\`\`
|
|
23
21
|
|
|
24
|
-
- If the task involves using, generating, or executing \`bkper\` CLI commands, read:
|
|
22
|
+
- If the task involves using, generating, or executing \`bkper\` CLI commands, read full file:
|
|
25
23
|
|
|
26
24
|
\`\`\`
|
|
27
25
|
${cliRefPath}
|
|
28
26
|
\`\`\`
|
|
29
27
|
|
|
28
|
+
- If the task involves writing, reviewing, or debugging code that uses the \`bkper-js\` library — such as Bkper, Book, Account, Transaction, Group classes, or any import from \`bkper-js\` — read both files:
|
|
29
|
+
|
|
30
|
+
\`\`\`
|
|
31
|
+
${bkperJsPath}
|
|
32
|
+
\`\`\`
|
|
33
|
+
|
|
34
|
+
\`\`\`
|
|
35
|
+
${bkperApiTypesPath}
|
|
36
|
+
\`\`\`
|
|
37
|
+
|
|
30
38
|
- For generic engineering work, do not load Bkper reference docs unless directly relevant.
|
|
31
39
|
- When scope is unclear, inspect local files and project instructions first; load reference docs only after identifying a concrete need.
|
|
40
|
+
- For any other question about Bkper — product features, accounting guides, app architecture, integrations, or general usage — fetch and read:
|
|
41
|
+
|
|
42
|
+
https://bkper.com/llms.txt
|
|
43
|
+
|
|
44
|
+
Then follow the most relevant link to find the answer.
|
|
32
45
|
`;
|
|
33
46
|
}
|
|
34
47
|
export const BKPER_AGENT_SYSTEM_PROMPT = `# Bkper Context
|
|
@@ -45,7 +58,7 @@ Available tools:
|
|
|
45
58
|
- edit: make precise file edits
|
|
46
59
|
- write: create or replace files
|
|
47
60
|
|
|
48
|
-
Guidelines:
|
|
61
|
+
IMPORTANT Guidelines:
|
|
49
62
|
- Use bash for discovery and search like ls, rg, and find. Use it to run bkper CLI commands when relevant.
|
|
50
63
|
- Use read to inspect file contents instead of cat or sed.
|
|
51
64
|
- Use edit for precise changes.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system-prompt.js","sourceRoot":"","sources":["../../src/agent/system-prompt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,SAAS,
|
|
1
|
+
{"version":3,"file":"system-prompt.js","sourceRoot":"","sources":["../../src/agent/system-prompt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,SAAS,cAAc,CAAC,QAAgB;IACpC,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;IAC7D,OAAO,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC;AACzD,CAAC;AAED,MAAM,UAAU,yBAAyB;IACrC,MAAM,UAAU,GAAG,cAAc,CAAC,kBAAkB,CAAC,CAAC;IACtD,MAAM,gBAAgB,GAAG,cAAc,CAAC,kBAAkB,CAAC,CAAC;IAC5D,MAAM,WAAW,GAAG,cAAc,CAAC,aAAa,CAAC,CAAC;IAClD,MAAM,iBAAiB,GAAG,cAAc,CAAC,oBAAoB,CAAC,CAAC;IAC/D,OAAO,GAAG,yBAAyB;;;;;;;EAOrC,gBAAgB;;;;;;EAMhB,UAAU;;;;;;EAMV,WAAW;;;;EAIX,iBAAiB;;;;;;;;;;CAUlB,CAAC;AACF,CAAC;AAED,MAAM,CAAC,MAAM,yBAAyB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgCxC,CAAC"}
|
|
@@ -0,0 +1,542 @@
|
|
|
1
|
+
# bkper-api-types
|
|
2
|
+
|
|
3
|
+
> TypeScript type definitions for the Bkper API — shared interfaces and enumerations.
|
|
4
|
+
|
|
5
|
+
This package contains Typescript definitions for the [Bkper REST API](https://bkper.com/docs/#rest-api).
|
|
6
|
+
|
|
7
|
+
The types are generated based on the Bkper [Open API spec](https://bkper.com/docs/api/rest/openapi.json) using the [dtsgenerator](https://github.com/horiuchi/dtsgenerator) tool.
|
|
8
|
+
|
|
9
|
+
More information at the [Bkper Developer Documentation](https://bkper.com/docs/#rest-api)
|
|
10
|
+
|
|
11
|
+
[](https://www.npmjs.com/package/@bkper/bkper-api-types) [](https://github.com/bkper/bkper-api-types)
|
|
12
|
+
|
|
13
|
+
### 2) Configure tsconfig.json:
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
{
|
|
17
|
+
"compilerOptions": {
|
|
18
|
+
"typeRoots" : ["node_modules/@bkper", "node_modules/@types" ]
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
[Learn more](https://www.typescriptlang.org/docs/handbook/tsconfig-json.html#types-typeroots-and-types) about **@types**, **typeRoots** and **types**
|
|
24
|
+
|
|
25
|
+
## Interfaces
|
|
26
|
+
|
|
27
|
+
### Account
|
|
28
|
+
|
|
29
|
+
**Properties:**
|
|
30
|
+
|
|
31
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
32
|
+
- `archived?`: `boolean` — Archived accounts are kept for history
|
|
33
|
+
- `balance?`: `string` — The current account balance, when querying transactions.
|
|
34
|
+
- `balanceVerified?`: `boolean` — Whether the account balance has been verified/audited
|
|
35
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
36
|
+
- `credit?`: `boolean` — Credit nature or Debit otherwise
|
|
37
|
+
- `groups?`: `bkper.Group[]` — The groups of the account
|
|
38
|
+
- `hasTransactionPosted?`: `boolean` — Tell if the account has transaction posted
|
|
39
|
+
- `id?`: `string` — The unique id that identifies the Account in the Book
|
|
40
|
+
- `name?`: `string` — The name of the Account
|
|
41
|
+
- `normalizedName?`: `string` — The name of the Account, lowercase, without spaces or special characters
|
|
42
|
+
- `permanent?`: `boolean` — Permanent are such as bank accounts, customers or the like
|
|
43
|
+
- `properties?`: `{ [name: string]: string }` — The key/value custom properties of the Account
|
|
44
|
+
- `type?`: `"ASSET" | "LIABILITY" | "INCOMING" | "OUTGOING"` — The type of the account
|
|
45
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
46
|
+
|
|
47
|
+
### AccountBalances
|
|
48
|
+
|
|
49
|
+
**Properties:**
|
|
50
|
+
|
|
51
|
+
- `archived?`: `boolean`
|
|
52
|
+
- `balances?`: `bkper.Balance[]`
|
|
53
|
+
- `credit?`: `boolean`
|
|
54
|
+
- `cumulativeBalance?`: `string`
|
|
55
|
+
- `cumulativeCredit?`: `string`
|
|
56
|
+
- `cumulativeDebit?`: `string`
|
|
57
|
+
- `empty?`: `boolean`
|
|
58
|
+
- `name?`: `string`
|
|
59
|
+
- `normalizedName?`: `string`
|
|
60
|
+
- `periodBalance?`: `string`
|
|
61
|
+
- `periodCredit?`: `string`
|
|
62
|
+
- `periodDebit?`: `string`
|
|
63
|
+
- `permanent?`: `boolean`
|
|
64
|
+
- `properties?`: `{ [name: string]: string }`
|
|
65
|
+
|
|
66
|
+
### AccountList
|
|
67
|
+
|
|
68
|
+
**Properties:**
|
|
69
|
+
|
|
70
|
+
- `items?`: `bkper.Account[]` — List items
|
|
71
|
+
|
|
72
|
+
### Agent
|
|
73
|
+
|
|
74
|
+
**Properties:**
|
|
75
|
+
|
|
76
|
+
- `id?`: `string` — The agent id
|
|
77
|
+
- `logo?`: `string` — The agent logo. Public url or Base64 encoded
|
|
78
|
+
- `logoDark?`: `string` — The agent logo on dark mode. Public url or Base64 encoded
|
|
79
|
+
- `name?`: `string` — The agent name
|
|
80
|
+
|
|
81
|
+
### App
|
|
82
|
+
|
|
83
|
+
**Properties:**
|
|
84
|
+
|
|
85
|
+
- `apiVersion?`: `"v0" | "v1" | "v2" | "v3" | "v4" | "v5"` — The API version of the event payload
|
|
86
|
+
- `clientId?`: `string` — The Google OAuth Client ID
|
|
87
|
+
- `clientSecret?`: `string` — The Google OAuth Client Secret
|
|
88
|
+
- `connectable?`: `boolean` — Tell if this app is connectable by a user
|
|
89
|
+
- `deprecated?`: `boolean` — Tell if the code app is deprecated
|
|
90
|
+
- `description?`: `string` — The App description
|
|
91
|
+
- `developers?`: `string` — The developers (usernames and domain patterns), comma or space separated
|
|
92
|
+
- `events?`: `("FILE_CREATED" | "FILE_UPDATED" | "TRANSACTION_CREATED" | "TRANSACTION_UPDATED" | "TRANSACTION_DELETED" | "TRANSACTION_POSTED" | "TRANSACTION_CHECKED" | "TRANSACTION_UNCHECKED" | "TRANSACTION_RESTORED" | "ACCOUNT_CREATED" | "ACCOUNT_UPDATED" | "ACCOUNT_DELETED" | "QUERY_CREATED" | "QUERY_UPDATED" | "QUERY_DELETED" | "GROUP_CREATED" | "GROUP_UPDATED" | "GROUP_DELETED" | "COMMENT_CREATED" | "COMMENT_DELETED" | "COLLABORATOR_ADDED" | "COLLABORATOR_UPDATED" | "COLLABORATOR_REMOVED" | "INTEGRATION_CREATED" | "INTEGRATION_UPDATED" | "INTEGRATION_DELETED" | "BOOK_CREATED" | "BOOK_AUDITED" | "BOOK_UPDATED" | "BOOK_DELETED")[]` — Event types the App listen to
|
|
93
|
+
- `filePatterns?`: `string[]` — File patters the App handles - wildcard accepted - E.g *.pdf *-bank.csv
|
|
94
|
+
- `id?`: `string` — The unique agent id of the App - this can't be changed after created
|
|
95
|
+
- `installable?`: `boolean` — Tell if this app is installable in a book
|
|
96
|
+
- `logoUrl?`: `string` — The App logo url
|
|
97
|
+
- `logoUrlDark?`: `string` — The App logo url in dark mode
|
|
98
|
+
- `menuPopupHeight?`: `string` — The menu popup window height
|
|
99
|
+
- `menuPopupWidth?`: `string` — The menu popup window width
|
|
100
|
+
- `menuText?`: `string` — The contex menu text - default to the App name
|
|
101
|
+
- `menuUrl?`: `string` — The context menu url
|
|
102
|
+
- `menuUrlDev?`: `string` — The context menu url in dev mode
|
|
103
|
+
- `name?`: `string` — The App name
|
|
104
|
+
- `ownerEmail?`: `string` — The owner user email
|
|
105
|
+
- `ownerId?`: `string` — The owner user id
|
|
106
|
+
- `ownerLogoUrl?`: `string` — The owner company logo url
|
|
107
|
+
- `ownerName?`: `string` — The owner company name
|
|
108
|
+
- `ownerWebsite?`: `string` — The owner company website url
|
|
109
|
+
- `propertiesSchema?`: `bkper.AppPropertiesSchema`
|
|
110
|
+
- `published?`: `boolean` — Tell if this app already published
|
|
111
|
+
- `readme?`: `string` — The readme.md file as string
|
|
112
|
+
- `readmeMd?`: `string` — The readme.md file as raw markdown string
|
|
113
|
+
- `repoPrivate?`: `boolean` — Tell if the code repository is private
|
|
114
|
+
- `repoUrl?`: `string` — The code repository url
|
|
115
|
+
- `scopes?`: `string[]` — The Google OAuth Scopes used by the app
|
|
116
|
+
- `users?`: `string` — The users (usernames and domain patterns) to enable the App while not yet published
|
|
117
|
+
- `webhookUrl?`: `string` — The Webhook endpoint URL to listen for book events
|
|
118
|
+
- `webhookUrlDev?`: `string` — The Webhook endpoint URL to listen for book events in dev mode
|
|
119
|
+
- `website?`: `string` — The App website url
|
|
120
|
+
|
|
121
|
+
### AppList
|
|
122
|
+
|
|
123
|
+
**Properties:**
|
|
124
|
+
|
|
125
|
+
- `items?`: `bkper.App[]`
|
|
126
|
+
|
|
127
|
+
### AppPropertiesSchema
|
|
128
|
+
|
|
129
|
+
**Properties:**
|
|
130
|
+
|
|
131
|
+
- `account?`: `bkper.AppPropertySchema`
|
|
132
|
+
- `book?`: `bkper.AppPropertySchema`
|
|
133
|
+
- `group?`: `bkper.AppPropertySchema`
|
|
134
|
+
- `transaction?`: `bkper.AppPropertySchema`
|
|
135
|
+
|
|
136
|
+
### AppPropertySchema
|
|
137
|
+
|
|
138
|
+
**Properties:**
|
|
139
|
+
|
|
140
|
+
- `keys?`: `string[]` — The property keys schema
|
|
141
|
+
- `values?`: `string[]` — The property values schema
|
|
142
|
+
|
|
143
|
+
### Backlog
|
|
144
|
+
|
|
145
|
+
**Properties:**
|
|
146
|
+
|
|
147
|
+
- `count?`: `number`
|
|
148
|
+
|
|
149
|
+
### Balance
|
|
150
|
+
|
|
151
|
+
**Properties:**
|
|
152
|
+
|
|
153
|
+
- `cumulativeBalance?`: `string`
|
|
154
|
+
- `cumulativeCredit?`: `string`
|
|
155
|
+
- `cumulativeDebit?`: `string`
|
|
156
|
+
- `day?`: `number`
|
|
157
|
+
- `fuzzyDate?`: `number`
|
|
158
|
+
- `month?`: `number`
|
|
159
|
+
- `periodBalance?`: `string`
|
|
160
|
+
- `periodCredit?`: `string`
|
|
161
|
+
- `periodDebit?`: `string`
|
|
162
|
+
- `year?`: `number`
|
|
163
|
+
|
|
164
|
+
### Balances
|
|
165
|
+
|
|
166
|
+
**Properties:**
|
|
167
|
+
|
|
168
|
+
- `accountBalances?`: `bkper.AccountBalances[]`
|
|
169
|
+
- `balancesUrl?`: `string`
|
|
170
|
+
- `groupBalances?`: `bkper.GroupBalances[]`
|
|
171
|
+
- `nextRange?`: `string`
|
|
172
|
+
- `periodicity?`: `"DAILY" | "MONTHLY" | "YEARLY"`
|
|
173
|
+
- `previousRange?`: `string`
|
|
174
|
+
- `range?`: `string`
|
|
175
|
+
- `rangeBeginLabel?`: `string`
|
|
176
|
+
- `rangeEndLabel?`: `string`
|
|
177
|
+
|
|
178
|
+
### Billing
|
|
179
|
+
|
|
180
|
+
**Properties:**
|
|
181
|
+
|
|
182
|
+
- `adminEmail?`: `string` — The billing admin email for the user's billing account
|
|
183
|
+
- `daysLeftInTrial?`: `number` — How many days the user has left in the trial period
|
|
184
|
+
- `email?`: `string` — The user's email address
|
|
185
|
+
- `enabled?`: `boolean` — True if billing is enabled for the user
|
|
186
|
+
- `hostedDomain?`: `string` — The user hosted domain
|
|
187
|
+
- `plan?`: `string` — The user's current plan
|
|
188
|
+
- `planOverdue?`: `boolean` — True if subscription payment is overdue
|
|
189
|
+
- `startedTrial?`: `boolean` — True if the user has started the trial period
|
|
190
|
+
- `totalTransactionsThisMonth?`: `number` — User-level total transactions this month
|
|
191
|
+
- `totalTransactionsThisYear?`: `number` — User-level total transactions this year
|
|
192
|
+
|
|
193
|
+
### Book
|
|
194
|
+
|
|
195
|
+
**Properties:**
|
|
196
|
+
|
|
197
|
+
- `accounts?`: `bkper.Account[]` — The book Accounts
|
|
198
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
199
|
+
- `autoPost?`: `boolean` — Tells if the Book has auto post enabled
|
|
200
|
+
- `closingDate?`: `string` — The book closing date
|
|
201
|
+
- `collection?`: `bkper.Collection`
|
|
202
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
203
|
+
- `datePattern?`: `string` — The date pattern of the Book. Example: dd/MM/yyyy
|
|
204
|
+
- `decimalSeparator?`: `"DOT" | "COMMA"` — The decimal separator of the Book
|
|
205
|
+
- `fractionDigits?`: `number` — The number of fraction digits (decimal places) of the Book
|
|
206
|
+
- `groups?`: `bkper.Group[]` — The book account Groups
|
|
207
|
+
- `id?`: `string` — The unique id that identifies the Book in the system. Found at bookId url param
|
|
208
|
+
- `lastUpdateMs?`: `string` — The last update date of the Book, in in milliseconds
|
|
209
|
+
- `lockDate?`: `string` — The book lock date
|
|
210
|
+
- `name?`: `string` — The name of the Book
|
|
211
|
+
- `ownerName?`: `string` — The Book owner username
|
|
212
|
+
- `pageSize?`: `number` — The transactions pagination page size
|
|
213
|
+
- `period?`: `"MONTH" | "QUARTER" | "YEAR"` — The period slice for balances visualization
|
|
214
|
+
- `periodStartMonth?`: `"JANUARY" | "FEBRUARY" | "MARCH" | "APRIL" | "MAY" | "JUNE" | "JULY" | "AUGUST" | "SEPTEMBER" | "OCTOBER" | "NOVEMBER" | "DECEMBER"` — The start month when YEAR period set
|
|
215
|
+
- `permission?`: `"OWNER" | "EDITOR" | "POSTER" | "RECORDER" | "VIEWER" | "NONE"` — The Permission the current user has in the Book
|
|
216
|
+
- `properties?`: `{ [name: string]: string }` — The key/value custom properties of the Book
|
|
217
|
+
- `timeZone?`: `string` — The time zone of the Book
|
|
218
|
+
- `timeZoneOffset?`: `number` — The time zone offset of the Book, in minutes
|
|
219
|
+
- `totalTransactions?`: `number` — The total transactions posted
|
|
220
|
+
- `totalTransactionsCurrentMonth?`: `number` — The total transactions posted on current month
|
|
221
|
+
- `totalTransactionsCurrentYear?`: `number` — The total transactions posted on current year
|
|
222
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
223
|
+
- `visibility?`: `"PUBLIC" | "PRIVATE"` — The Visibility of the Book
|
|
224
|
+
|
|
225
|
+
### BookList
|
|
226
|
+
|
|
227
|
+
**Properties:**
|
|
228
|
+
|
|
229
|
+
- `items?`: `bkper.Book[]` — List items
|
|
230
|
+
|
|
231
|
+
### BotResponse
|
|
232
|
+
|
|
233
|
+
**Properties:**
|
|
234
|
+
|
|
235
|
+
- `agentId?`: `string`
|
|
236
|
+
- `createdAt?`: `string`
|
|
237
|
+
- `message?`: `string`
|
|
238
|
+
- `type?`: `"INFO" | "WARNING" | "ERROR"`
|
|
239
|
+
|
|
240
|
+
### Collaborator
|
|
241
|
+
|
|
242
|
+
**Properties:**
|
|
243
|
+
|
|
244
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
245
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
246
|
+
- `email?`: `string` — The email of the Collaborator
|
|
247
|
+
- `id?`: `string` — The unique id that identifies the Collaborator in the Book
|
|
248
|
+
- `permission?`: `"OWNER" | "EDITOR" | "POSTER" | "RECORDER" | "VIEWER" | "NONE"` — The permission the Collaborator has in the Book
|
|
249
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
250
|
+
|
|
251
|
+
### CollaboratorPayloadCollection
|
|
252
|
+
|
|
253
|
+
**Properties:**
|
|
254
|
+
|
|
255
|
+
- `items?`: `bkper.Collaborator[]`
|
|
256
|
+
|
|
257
|
+
### Collection
|
|
258
|
+
|
|
259
|
+
**Properties:**
|
|
260
|
+
|
|
261
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
262
|
+
- `books?`: `bkper.Book[]` — The Books contained in the Collection
|
|
263
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
264
|
+
- `id?`: `string` — The unique id of the Collection
|
|
265
|
+
- `name?`: `string` — The name of the Collection
|
|
266
|
+
- `ownerUsername?`: `string` — The username of the Collection owner
|
|
267
|
+
- `permission?`: `"OWNER" | "EDITOR" | "POSTER" | "RECORDER" | "VIEWER" | "NONE"`
|
|
268
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
269
|
+
|
|
270
|
+
### CollectionList
|
|
271
|
+
|
|
272
|
+
**Properties:**
|
|
273
|
+
|
|
274
|
+
- `items?`: `bkper.Collection[]` — List items
|
|
275
|
+
|
|
276
|
+
### Connection
|
|
277
|
+
|
|
278
|
+
**Properties:**
|
|
279
|
+
|
|
280
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
281
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
282
|
+
- `dateAddedMs?`: `string`
|
|
283
|
+
- `email?`: `string`
|
|
284
|
+
- `id?`: `string`
|
|
285
|
+
- `logo?`: `string`
|
|
286
|
+
- `name?`: `string`
|
|
287
|
+
- `properties?`: `{ [name: string]: string }`
|
|
288
|
+
- `type?`: `"APP" | "BANK"`
|
|
289
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
290
|
+
- `userId?`: `string`
|
|
291
|
+
- `uuid?`: `string`
|
|
292
|
+
|
|
293
|
+
### ConnectionList
|
|
294
|
+
|
|
295
|
+
**Properties:**
|
|
296
|
+
|
|
297
|
+
- `items?`: `bkper.Connection[]` — List items
|
|
298
|
+
|
|
299
|
+
### Count
|
|
300
|
+
|
|
301
|
+
**Properties:**
|
|
302
|
+
|
|
303
|
+
- `day?`: `number`
|
|
304
|
+
- `fuzzyDate?`: `number`
|
|
305
|
+
- `month?`: `number`
|
|
306
|
+
- `total?`: `number`
|
|
307
|
+
- `year?`: `number`
|
|
308
|
+
|
|
309
|
+
### Counts
|
|
310
|
+
|
|
311
|
+
**Properties:**
|
|
312
|
+
|
|
313
|
+
- `posted?`: `bkper.Count[]`
|
|
314
|
+
- `trashed?`: `bkper.Count[]`
|
|
315
|
+
|
|
316
|
+
### Event
|
|
317
|
+
|
|
318
|
+
**Properties:**
|
|
319
|
+
|
|
320
|
+
- `agent?`: `bkper.Agent`
|
|
321
|
+
- `book?`: `bkper.Book`
|
|
322
|
+
- `bookId?`: `string` — The id of the Book associated to the Event
|
|
323
|
+
- `botResponses?`: `bkper.BotResponse[]` — The list of bot responses associated to the Event
|
|
324
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
325
|
+
- `createdOn?`: `string` — The creation date time on RFC3339 format
|
|
326
|
+
- `data?`: `bkper.EventData`
|
|
327
|
+
- `id?`: `string` — The unique id that identifies the Event
|
|
328
|
+
- `resource?`: `string` — The resource associated to the Event
|
|
329
|
+
- `type?`: `"FILE_CREATED" | "FILE_UPDATED" | "TRANSACTION_CREATED" | "TRANSACTION_UPDATED" | "TRANSACTION_DELETED" | "TRANSACTION_POSTED" | "TRANSACTION_CHECKED" | "TRANSACTION_UNCHECKED" | "TRANSACTION_RESTORED" | "ACCOUNT_CREATED" | "ACCOUNT_UPDATED" | "ACCOUNT_DELETED" | "QUERY_CREATED" | "QUERY_UPDATED" | "QUERY_DELETED" | "GROUP_CREATED" | "GROUP_UPDATED" | "GROUP_DELETED" | "COMMENT_CREATED" | "COMMENT_DELETED" | "COLLABORATOR_ADDED" | "COLLABORATOR_UPDATED" | "COLLABORATOR_REMOVED" | "INTEGRATION_CREATED" | "INTEGRATION_UPDATED" | "INTEGRATION_DELETED" | "BOOK_CREATED" | "BOOK_AUDITED" | "BOOK_UPDATED" | "BOOK_DELETED"` — The type of the Event
|
|
330
|
+
- `user?`: `bkper.User`
|
|
331
|
+
|
|
332
|
+
### EventData
|
|
333
|
+
|
|
334
|
+
**Properties:**
|
|
335
|
+
|
|
336
|
+
- `object?`: `bkper.Any`
|
|
337
|
+
- `previousAttributes?`: `{ [name: string]: string }` — The object previous attributes when updated
|
|
338
|
+
|
|
339
|
+
### EventList
|
|
340
|
+
|
|
341
|
+
**Properties:**
|
|
342
|
+
|
|
343
|
+
- `cursor?`: `string` — The cursor, for pagination
|
|
344
|
+
- `items?`: `bkper.Event[]` — List items
|
|
345
|
+
|
|
346
|
+
### File
|
|
347
|
+
|
|
348
|
+
**Properties:**
|
|
349
|
+
|
|
350
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
351
|
+
- `content?`: `string` — The file content Base64 encoded
|
|
352
|
+
- `contentType?`: `string` — The file content type
|
|
353
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
354
|
+
- `id?`: `string` — The unique id that identifies the file in the book
|
|
355
|
+
- `name?`: `string` — The file name
|
|
356
|
+
- `properties?`: `{ [name: string]: string }` — The key/value custom properties of the File
|
|
357
|
+
- `size?`: `number` — The file size in bytes
|
|
358
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
359
|
+
- `url?`: `string` — The file serving url
|
|
360
|
+
|
|
361
|
+
### Group
|
|
362
|
+
|
|
363
|
+
**Properties:**
|
|
364
|
+
|
|
365
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
366
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
367
|
+
- `credit?`: `boolean` — Tell if the group is credit
|
|
368
|
+
- `hasAccounts?`: `boolean` — Tell if the group is has any accounts
|
|
369
|
+
- `hasGroups?`: `boolean` — Tell if the group is has any children groups
|
|
370
|
+
- `hidden?`: `boolean` — Tell if the group is hidden on transactions main menu
|
|
371
|
+
- `id?`: `string` — The unique id that identifies the Group in the Book
|
|
372
|
+
- `locked?`: `boolean` — Tell if the group is locked by the Book owner
|
|
373
|
+
- `mixed?`: `boolean` — Tell if has mixed type of accounts
|
|
374
|
+
- `name?`: `string` — The name of the Group
|
|
375
|
+
- `normalizedName?`: `string` — The name of the Group, lowercase, without spaces or special characters
|
|
376
|
+
- `parent?`: `bkper.Group`
|
|
377
|
+
- `permanent?`: `boolean` — Tell if the group is permanent
|
|
378
|
+
- `properties?`: `{ [name: string]: string }` — The key/value custom properties of the Group
|
|
379
|
+
- `type?`: `"ASSET" | "LIABILITY" | "INCOMING" | "OUTGOING"`
|
|
380
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
381
|
+
|
|
382
|
+
### GroupBalances
|
|
383
|
+
|
|
384
|
+
**Properties:**
|
|
385
|
+
|
|
386
|
+
- `accountBalances?`: `bkper.AccountBalances[]`
|
|
387
|
+
- `balances?`: `bkper.Balance[]`
|
|
388
|
+
- `credit?`: `boolean`
|
|
389
|
+
- `cumulativeBalance?`: `string`
|
|
390
|
+
- `cumulativeCredit?`: `string`
|
|
391
|
+
- `cumulativeDebit?`: `string`
|
|
392
|
+
- `groupBalances?`: `bkper.GroupBalances[]`
|
|
393
|
+
- `name?`: `string`
|
|
394
|
+
- `normalizedName?`: `string`
|
|
395
|
+
- `periodBalance?`: `string`
|
|
396
|
+
- `periodCredit?`: `string`
|
|
397
|
+
- `periodDebit?`: `string`
|
|
398
|
+
- `permanent?`: `boolean`
|
|
399
|
+
- `properties?`: `{ [name: string]: string }`
|
|
400
|
+
|
|
401
|
+
### GroupList
|
|
402
|
+
|
|
403
|
+
**Properties:**
|
|
404
|
+
|
|
405
|
+
- `items?`: `bkper.Group[]` — List items
|
|
406
|
+
|
|
407
|
+
### Integration
|
|
408
|
+
|
|
409
|
+
**Properties:**
|
|
410
|
+
|
|
411
|
+
- `addedBy?`: `string`
|
|
412
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
413
|
+
- `bookId?`: `string`
|
|
414
|
+
- `connectionId?`: `string`
|
|
415
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
416
|
+
- `dateAddedMs?`: `string`
|
|
417
|
+
- `id?`: `string`
|
|
418
|
+
- `lastUpdateMs?`: `string`
|
|
419
|
+
- `logo?`: `string`
|
|
420
|
+
- `logoDark?`: `string`
|
|
421
|
+
- `name?`: `string`
|
|
422
|
+
- `normalizedName?`: `string`
|
|
423
|
+
- `properties?`: `{ [name: string]: string }`
|
|
424
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
425
|
+
- `userId?`: `string`
|
|
426
|
+
|
|
427
|
+
### IntegrationList
|
|
428
|
+
|
|
429
|
+
**Properties:**
|
|
430
|
+
|
|
431
|
+
- `items?`: `bkper.Integration[]` — List items
|
|
432
|
+
|
|
433
|
+
### Query
|
|
434
|
+
|
|
435
|
+
**Properties:**
|
|
436
|
+
|
|
437
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
438
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
439
|
+
- `id?`: `string` — The unique id that identifies the saved Query in the Book
|
|
440
|
+
- `query?`: `string` — The Query string to be executed
|
|
441
|
+
- `title?`: `string` — The title of the saved Query
|
|
442
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
443
|
+
|
|
444
|
+
### QueryList
|
|
445
|
+
|
|
446
|
+
**Properties:**
|
|
447
|
+
|
|
448
|
+
- `items?`: `bkper.Query[]` — List items
|
|
449
|
+
|
|
450
|
+
### Template
|
|
451
|
+
|
|
452
|
+
**Properties:**
|
|
453
|
+
|
|
454
|
+
- `bookId?`: `string`
|
|
455
|
+
- `bookLink?`: `string`
|
|
456
|
+
- `category?`: `string`
|
|
457
|
+
- `description?`: `string`
|
|
458
|
+
- `imageUrl?`: `string`
|
|
459
|
+
- `name?`: `string`
|
|
460
|
+
- `sheetsLink?`: `string`
|
|
461
|
+
- `timesUsed?`: `number`
|
|
462
|
+
|
|
463
|
+
### TemplateList
|
|
464
|
+
|
|
465
|
+
**Properties:**
|
|
466
|
+
|
|
467
|
+
- `items?`: `bkper.Template[]` — List items
|
|
468
|
+
|
|
469
|
+
### Transaction
|
|
470
|
+
|
|
471
|
+
**Properties:**
|
|
472
|
+
|
|
473
|
+
- `agentId?`: `string` — The id of agent that created the resource
|
|
474
|
+
- `agentLogo?`: `string` — The logo of the agent that created the transaction
|
|
475
|
+
- `agentLogoDark?`: `string` — The logo in dark mode, of the agent that created the transaction
|
|
476
|
+
- `agentName?`: `string` — The name of the agent that created the transaction
|
|
477
|
+
- `amount?`: `string` — The amount on format ####.##
|
|
478
|
+
- `checked?`: `boolean` — Tell if the transaction is a checked
|
|
479
|
+
- `createdAt?`: `string` — The creation timestamp, in milliseconds
|
|
480
|
+
- `createdBy?`: `string` — The actor username that created the transaction
|
|
481
|
+
- `creditAccount?`: `bkper.Account`
|
|
482
|
+
- `date?`: `string` — The date on ISO format yyyy-MM-dd
|
|
483
|
+
- `dateFormatted?`: `string` — The date on format of the Book
|
|
484
|
+
- `dateValue?`: `number` — The date number representation on format YYYYMMDD
|
|
485
|
+
- `debitAccount?`: `bkper.Account`
|
|
486
|
+
- `description?`: `string` — The transaction description
|
|
487
|
+
- `draft?`: `boolean` — Tell if its a draft transaction
|
|
488
|
+
- `files?`: `bkper.File[]` — The files attached to the transaction
|
|
489
|
+
- `id?`: `string` — The unique id that identifies the transaction in the book
|
|
490
|
+
- `posted?`: `boolean` — Tell if the transaction is already posted on accounts, otherwise is a draft
|
|
491
|
+
- `properties?`: `{ [name: string]: string }` — The key/value custom properties of the Transaction
|
|
492
|
+
- `remoteIds?`: `string[]` — The transaction remote ids, to avoid duplication
|
|
493
|
+
- `tags?`: `string[]` — The transaction #hashtags
|
|
494
|
+
- `trashed?`: `boolean` — Tell if transaction is trashed
|
|
495
|
+
- `updatedAt?`: `string` — The last update timestamp, in milliseconds
|
|
496
|
+
- `urls?`: `string[]` — The transaction urls
|
|
497
|
+
|
|
498
|
+
### TransactionList
|
|
499
|
+
|
|
500
|
+
**Properties:**
|
|
501
|
+
|
|
502
|
+
- `account?`: `string` — The account id when filtering by a single account. E.g. account='Bank'
|
|
503
|
+
- `cursor?`: `string` — The cursor, for pagination
|
|
504
|
+
- `items?`: `bkper.Transaction[]` — List items
|
|
505
|
+
|
|
506
|
+
### TransactionOperation
|
|
507
|
+
|
|
508
|
+
**Properties:**
|
|
509
|
+
|
|
510
|
+
- `accounts?`: `bkper.Account[]` — The affected accounts
|
|
511
|
+
- `transaction?`: `bkper.Transaction`
|
|
512
|
+
|
|
513
|
+
### Url
|
|
514
|
+
|
|
515
|
+
**Properties:**
|
|
516
|
+
|
|
517
|
+
- `url?`: `string`
|
|
518
|
+
|
|
519
|
+
### User
|
|
520
|
+
|
|
521
|
+
**Properties:**
|
|
522
|
+
|
|
523
|
+
- `avatarUrl?`: `string` — The user public avatar url
|
|
524
|
+
- `bankConnections?`: `boolean` — True if user already had any bank connection
|
|
525
|
+
- `billingAdminEmail?`: `string` — The billing admin email for this user's billing account
|
|
526
|
+
- `billingEnabled?`: `boolean` — True if billing is enabled for the user
|
|
527
|
+
- `daysLeftInTrial?`: `number` — How many days left in trial
|
|
528
|
+
- `email?`: `string` — The user email
|
|
529
|
+
- `free?`: `boolean` — True if user is in the free plan
|
|
530
|
+
- `fullName?`: `string` — The user full name
|
|
531
|
+
- `givenName?`: `string` — The user given name
|
|
532
|
+
- `hash?`: `string` — The user hash
|
|
533
|
+
- `hostedDomain?`: `string` — The user hosted domain
|
|
534
|
+
- `id?`: `string` — The user unique id
|
|
535
|
+
- `name?`: `string` — The user display name
|
|
536
|
+
- `plan?`: `string` — The user plan
|
|
537
|
+
- `planOverdue?`: `boolean` — True if subscription payment is overdue
|
|
538
|
+
- `startedTrial?`: `boolean` — True if user started trial
|
|
539
|
+
- `totalTransactionsThisMonth?`: `number` — User-level total transactions this month
|
|
540
|
+
- `totalTransactionsThisYear?`: `number` — User-level total transactions this year
|
|
541
|
+
- `username?`: `string` — The Bkper username of the user
|
|
542
|
+
|