kintone / js-sdk Goto Github PK
View Code? Open in Web Editor NEWA monorepo for Kintone development tools :wrench:
License: MIT License
A monorepo for Kintone development tools :wrench:
License: MIT License
for
I want to know which version a RestAPIClient is used from UMD builds.
e.g. React has a version
property as React.version
.
I have three options.
Personally, I prefer option 1.
KintoneRestAPIClient.version
// "1.3.0"
const client = new KintoneRestAPIClient();
client.version;
// "1.3.0"
// Version: 1.3.0
This should keep the comment even after minification for the production build.
We want to use rest-api-client for the subdomain in which Client Certificate Authentication is enabled
NOTE: This feature is available only in Node.js environment.
We haven't fixed the interface and need to discuss, but something like the following: The client can accept the client certificate file and its password.
const client = new KintoneRestAPIClient({
baseUrl: "https://example.cybozu.com",
auth: {
clientCert: {
file: fs.readFileSync('PATH_TO_CERT_FILE'), // or the path to certificate file
password: 'PASSWORD'
}
}
});
Step 1. Create a new kintone app, no field is OK.
Step 2. Add more than 500 records.
Step 3. On JS Customization page of this APP, add the UMD file of rest-api-client.
Step 4. On list page of this APP, open DevTools of browser and run following code.
const client = new KintoneRestAPIClient(); client.record .getAllRecordsWithId({ app: kintone.app.getId(), condition: '$id != "" or $id = ""' }) .then((resp) => { console.log(resp); }) .catch((err) => { console.log(err); });
=> Bug occurs:
The API requests are send continuously.
Always return the first 500 records.
Memo:
If condition is '($id != "" or $id = "")', this bug does not occur.
I think adding () in rest-api-client is better.
Do not send requests continuously.
Return the correct result.
app.updateGeneralNotifications
(#607 ) accepts notifications[].notifyToCommenter
for their parameter.
Remove notifications[].notifyToCommenter
from the type definition.
According to cybozu developer network, notificatons[] doesn't require the property notifyToCommenter
.
https://developer.cybozu.io/hc/ja/articles/900004873663
N/A
ref. kintone/js-sdk-ja#8
We should support the way of recognizing if the request fails due to network timeout.
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
Warning
These dependencies are deprecated:
Datasource | Name | Replacement PR? |
---|---|---|
npm | @types/js-base64 |
|
npm | @types/mime |
These updates have been manually edited so Renovate will no longer make changes. To discard all commits and start over, click on a checkbox.
These updates have all been created already. Click a checkbox below to force a retry/rebase of any.
These are blocked by an existing closed PR and will not be recreated unless you click a checkbox below.
inquirer
, @types/inquirer
)mime
, @types/mime
).github/workflows/labeler.yml
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
actions/labeler v5
.github/workflows/license.yml
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
.github/workflows/lint.yml
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
.github/workflows/release.yml
actions/create-github-app-token v1
googleapis/release-please-action v4@7987652d64b4581673a76e33ad5e98e3dd56832f
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
.github/workflows/test-e2e.yml
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
.github/workflows/test.yml
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
.github/workflows/yamory.yml
Kesin11/actions-timeline v2@1c2ab3f28225878ae4dd1f76d31279f16ea29e29
actions/checkout v4
pnpm/action-setup v3
actions/setup-node v4
examples/rest-api-client-demo/package.json
@kintone/rest-api-client ^5.5.2
yargs ^17.7.2
@kintone/customize-uploader ^8.0.13
@types/yargs ^17.0.32
ts-loader ^9.5.1
ts-node ^10.9.2
webpack ^5.92.0
webpack-cli 5.1.4
package.json
@babel/core ^7.24.7
@babel/preset-env ^7.24.7
@babel/preset-typescript ^7.24.7
@cybozu/eslint-config ^23.0.0
@cybozu/license-manager ^1.2.1
@octokit/rest ^20.1.1
@types/jest ^29.5.12
@types/node ^18.19.37
babel-jest ^29.7.0
comment-json ^4.2.3
eslint ^8.57.0
jest ^29.7.0
npm-run-all ^4.1.5
prettier ^3.3.2
rimraf ^5.0.7
ts-node ^10.9.2
typescript ^5.4.5
pnpm 8.15.8
braces >=3.0.3
pac-resolver >=7.0.1
socks >=2.8.3
express >=4.19.2
packages/create-plugin/package.json
chalk ^4.1.2
glob ^10.4.1
inquirer ^8.2.6
lodash ^4.17.21
meow ^9.0.0
node-rsa ^1.1.1
normalize-path ^3.0.0
os-locale ^5.0.0
prettier ^3.3.2
rimraf ^5.0.7
sort-package-json ^1.57.0
@types/glob ^8.1.0
@types/inquirer ^8.2.10
@types/lodash ^4.17.5
@types/node-rsa ^1.1.4
@types/normalize-path ^3.0.2
cross-env ^7.0.3
jest-environment-node ^29.7.0
packages/create-plugin/templates/minimum/package.json
@cybozu/eslint-config ^23.0.0
@kintone/plugin-packer ^8.1.2
eslint ^8.57.0
packages/create-plugin/templates/minimum/with-plugin-uploader.json
@kintone/plugin-uploader ^9.1.2
npm-run-all ^4.1.5
packages/create-plugin/templates/modern/package.json
core-js ^3.37.1
@kintone/rest-api-client ^5.5.2
@babel/core ^7.24.7
@babel/preset-env ^7.24.7
@babel/preset-react ^7.24.7
@babel/preset-typescript ^7.24.7
@cybozu/eslint-config ^23.0.0
@kintone/dts-gen ^8.0.12
@kintone/webpack-plugin-kintone-plugin ^8.0.9
ajv ^8.16.0
babel-loader ^9.1.3
cross-env ^7.0.3
eslint ^8.57.0
npm-run-all ^4.1.5
prettier ^3.3.2
typescript ^5.4.5
webpack ^5.92.0
webpack-cli ^5.1.4
packages/create-plugin/templates/modern/with-plugin-uploader.json
@kintone/plugin-uploader ^9.1.2
packages/customize-uploader/package.json
@kintone/rest-api-client ^5.5.2
chokidar ^3.6.0
inquirer ^8.2.6
meow ^9.0.0
mkdirp ^3.0.1
os-locale ^5.0.0
rimraf ^5.0.7
@types/inquirer 8.2.10
packages/dts-gen/package.json
@cybozu/eslint-config ^23.0.0
axios ^1.7.2
commander ^12.1.0
eslint ^8.57.0
form-data ^4.0.0
lodash ^4.17.21
prettier ^3.3.2
@types/eslint ^8.56.10
@types/lodash ^4.17.5
ts-loader ^9.5.1
webpack ^5.92.0
webpack-cli ^5.1.4
assert ^2.1.0
packages/plugin-manifest-validator/package.json
ajv ^8.16.0
ajv-formats ^3.0.1
bytes ^3.1.2
@babel/preset-typescript ^7.24.7
@types/bytes ^3.1.4
babel-plugin-replace-ts-export-assignment ^0.0.2
intelli-espower-loader ^1.1.0
json-schema-to-typescript ^14.0.5
power-assert ^1.6.1
packages/plugin-packer/package.json
@kintone/plugin-manifest-validator ^10.2.2
chokidar ^3.6.0
debug ^4.3.5
denodeify ^1.2.1
meow ^9.0.0
mkdirp ^3.0.1
node-rsa ~1.1.1
stream-buffers ^3.0.3
yauzl ^3.1.3
yazl ^2.5.1
@reduxjs/toolkit ^2.2.5
@types/debug ^4.1.12
@types/node-rsa ^1.1.4
@types/stream-buffers ^3.0.7
@types/yauzl ^2.10.3
@types/yazl ^2.4.5
ajv ^8.16.0
array-flatten ^3.0.0
assert ^2.1.0
babel-plugin-replace-ts-export-assignment ^0.0.2
browserify-zlib ^0.2.0
buffer ^6.0.3
constants-browserify ^1.0.0
crypto-browserify ^3.12.0
cssnano ^7.0.3
execa ^5.1.1
glob ^10.4.1
jest-environment-jsdom ^29.7.0
normalize.css ^8.0.1
path-browserify ^1.0.1
postcss ^8.4.38
postcss-cli ^11.0.0
process ^0.11.10
redux-logger ^3.0.6
redux-thunk ^3.1.0
rimraf ^5.0.7
setimmediate ^1.0.5
stream-browserify ^3.0.0
util ^0.12.5
webpack ^5.92.0
webpack-cli 5.1.4
webpack-dev-server ^5.0.4
packages/plugin-uploader/package.json
chalk ^4.1.2
inquirer ^8.2.6
meow ^9.0.0
os-locale ^5.0.0
puppeteer ^22.10.1
@types/inquirer 8.2.10
packages/profile-loader/package.json
toml ^3.0.0
packages/rest-api-client/package.json
core-js ^3.37.1
axios ^1.7.2
form-data ^4.0.0
js-base64 ^3.7.7
mime ^3.0.0
qs ^6.12.1
@rollup/plugin-babel ^6.0.4
@rollup/plugin-commonjs ^26.0.1
@rollup/plugin-json ^6.1.0
@rollup/plugin-node-resolve ^15.2.3
@rollup/plugin-terser ^0.4.4
@types/core-js ^2.5.8
@types/js-base64 ^3.3.1
@types/mime ^3.0.4
@types/qs ^6.9.15
rollup ^4.18.0
rollup-plugin-ecma-version-validator ^0.2.13
rollup-plugin-license ^3.4.0
rollup-plugin-node-globals ^1.4.0
rollup-plugin-polyfill-node ^0.13.0
webpack ^5.92.0
webpack-cli ^5.1.4
babel-loader ^9.1.3
vite ^5.3.1
rimraf ^5.0.7
cross-env ^7.0.3
packages/webpack-plugin-kintone-plugin/package.json
@kintone/plugin-packer ^8.1.2
mkdirp ^3.0.1
@types/adm-zip ^0.5.5
adm-zip ^0.5.14
chokidar ^3.6.0
rimraf ^5.0.7
webpack ^5.92.0
webpack-cli 5.1.4
webpack-merge ^5.10.0
webpack ^4.0.0 || ^5.0.0
It looks like --proxy
option is not passed to api client.
js-sdk/packages/customize-uploader/src/KintoneApiClient.ts
Lines 53 to 61 in a6c7ee5
--proxy
option works correctly
The current limitation of updateRecords
(limited until 100 records) is inconvenient so we'd like to add a method to be able to exceed the limitation.
This method is to be able to update over 100 records to an app.
Here is the interface we plan.
const results = await this.client.record.updateAllRecords({
app: APP_ID,
records
});
Error: [520] [GAIA_LO04] A value 129 in the field xxx does not exist in the datasource app for lookup, or you do not have permission to view the app or the field.
Hi, I keep getting this error message when updating a lookup field of an app, there is nothing wrong when I update other types of fields.
Can you tell me how to solve this problem?
Thanks a lot.
Currently, @kintone/plugin-manifest-validator pass-through the Ajv ErrorObject
.
It has increased the impact of the disruptive update of Ajv. ( see #786 )
Wrapping in its own error format minimizes external impact.
TBD
This behavior is related to #855, but still occurs even after merging #855.
expo-cli
$ npm install --global expo-cli
$ expo init my-project
@kintone/rest-api-client
$ npm install @kintone/rest-api-client
App.tsx
to create KintoneRestAPIClient without baseUrl
import React from 'react';
import { StyleSheet, Text, View } from 'react-native';
+import { KintoneRestAPIClient } from "@kintone/rest-api-client";
+
export default function App() {
+ const client = new KintoneRestAPIClient();
+
return (
<View style={styles.container}>
<Text>Open up App.tsx to start working on your app!</Text>
npm start
and open the app with Expo Go (in iPhone or Android phone)Then an error occurs.
ReferenceError: Can't find variable: location
It would be nice if we can see more helpful error message.
(For example, "In this environment, `baseUrl` is required"
)
We want to use rest-api-client under the network using proxy server.
NOTE: This feature is available only in Node.js environment.
We haven't fixed the interface and need to discuss, but something like the following: The client can accept the proxy server configurations.
const client = new KintoneRestAPIClient({
baseUrl: "https://example.cybozu.com",
proxy: 'http://our-proxy-server:port',
// ...
});
Or we can respect environment variables such as HTTP_PROXY
/ HTTPS_PROXY
.
ref. https://github.com/googleapis/google-api-nodejs-client#using-a-proxy
In kintone.d.ts, The type
property is optional for most field types.
https://github.com/kintone/dts-gen/blob/353ac959a38844f23e4f8fc0f928c9d0263fbd42/kintone.d.ts#L261
However, only Calc
and File
are requires type
.
https://github.com/kintone/dts-gen/blob/353ac959a38844f23e4f8fc0f928c9d0263fbd42/kintone.d.ts#L289
https://github.com/kintone/dts-gen/blob/353ac959a38844f23e4f8fc0f928c9d0263fbd42/kintone.d.ts#L372
Is there a reason for this?
This plan is a roadmap for the next few months.
We will introduce item details in each issue.
x-cybozu-warning
header (#67)
🏃 ... work in progress
🤔 ... under discussion
✋ ... postpone
Japanese version: kintone/js-sdk-ja#2
The current limitation of deleteRecords
(limited until 100 records) is inconvenient so we'd like to add a method to be able to exceed the limitation.
This method is to be able to delete over 100 records to an app.
Here is the interface we plan.
const results = await this.client.record.deleteAllRecords({
app: APP_ID,
ids,
revisions
});
Following the Maintenance Guide of @kintone/dts-gen
, I executed yarn build
& node ./dist/integration-tests/setup-test-app.js
with some parameters written in the guide.
However, we got the error like bellow:
/path/to/workspace/js-sdk/packages/dts-gen/dist/integration-tests/setup-test-app.js:37
.version("0.0.1")
^
TypeError: program.version is not a function
at Object.<anonymous> (/path/to/workspace/js-sdk/packages/dts-gen/dist/integration-tests/setup-test-app.js:37:6)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at internal/main/run_main_module.js:17:47
can execute the setup script with no error.
kintone-js-sdk のように、file.data で Streamを受け取れるようにしていただけると嬉しいです。
these are helpful for contributors, so I'd like to put them in the repository.
I need support for OAuth access token authorization feature.
https://developer.kintone.io/hc/en-us/articles/360001562353/
setting the access token in the Authorization: Bearer header.
This feature has been waiting for a long time ago.
kintone-labs/kintone-basejs-sdk#65
kintone-labs/kintone-js-sdk#32
rest-api-client
supports Node and a browser environment, but some features are only available in one environment.
We run unit testing using Jest, so the unit tests are running on jsdom
, which is a default environment for Jest.
Currently, it's not clear which tests are for a browser environment, which one is for a Node environment.
So we have to refactor tests to make a running environment clear.
IMHO, we might not need to use jsdom
as the environment, because most tests should run on a Node environment.
Option "guest-space-id" does not work when I use @kintone/customize-uploader to upload JS file to a guest space app.
Preparation: A guest space, and an app in this space
Steps to reproduce:
E:\github.com\kintone\test>npx kintone-customize-uploader .\dest\customize-manifest.json --guest-space-id 5
? Input your kintone's base URL (https://example.cybozu.com): https://ldong.cybozu.com
? Input your username: test
? Input your password: [hidden]
Start uploading customization files
dest/test.js has been uploaded!
JavaScript/CSS files have been uploaded!
Failed to update customize setting
An error occured, retry
Failed to update customize setting
An error occured, retry
Failed to update customize setting
KintoneRestAPIError: [520] [GAIA_IL23] ゲストスペース内のアプリを操作する場合は、リクエストの送信先を「/k/guest/(ゲストスペースのID)/v1/...」にします。 (TdYjpvnw4Rj5kTL0p4JP)
at KintoneResponseHandler.handleErrorResponse (E:\github.com\kintone\test\node_modules\@kintone\rest-api-client\lib\KintoneResponseHandler.js:57:15)
at E:\github.com\kintone\test\node_modules\@kintone\rest-api-client\lib\KintoneResponseHandler.js:35:123
at processTicksAndRejections (internal/process/task_queues.js:93:5)
Maybe problem is here, parameter "guestSpaceId" is missing.
js-sdk/packages/customize-uploader/src/KintoneApiClient.ts
Lines 49 to 56 in ea98942
Can use @kintone/customize-uploader to upload JS file to a guest space app.
The return type of totalCount
is described as String
even though the value of totalCount
will be null
when the request parameter totalCount
is set to false
or ignored. I assume that the description should be String
or null
.
The return type of the totalCount
is String
even though the type is described as Integer
on the reference page. I did not confirm which one is true, but we should fix either of them.
createCursor - Returns
https://github.com/kintone/js-sdk/blob/master/packages/rest-api-client/docs/record.md#returns-18
createCursor - Reference
https://github.com/kintone/js-sdk/blob/master/packages/rest-api-client/docs/record.md#reference-10
ref. #66
Recently, You have updated Axios version to "^0.21.0".
It cause that request body byte size has been limited.
I think that limited 10MB. it's axios default limit
I think you know solution.
You have wrote note. and useful configuration statement has commentouted.
// maxBodyLength: Infinity,
https://github.com/kintone/js-sdk/blob/master/packages/rest-api-client/src/http/AxiosClient.ts#L88-L93
I think that the option parameter is necessary to use current version Axios.
Or We need A way to set maxBodyLengh parameter.
Please tell me any opinion.
https://github.com/kintone/js-sdk/blob/master/packages/rest-api-client/docs/file.md#uploadFile
の Parameters に
file.data String or Blob と書かれており、このページの冒頭にも
const FILE = {
name: "Hello.txt",
data: "Hello World!"
};
file.data に文字列を指定する例が書かれていますが、
Uncaught (in promise) TypeError: Failed to execute 'append' on 'FormData': parameter 2 is not of type 'Blob'.
が発生します。
const blob = new Blob(["Hello World!"], {
type: 'text/plain'
});
const { fileKey } = await client.file.uploadFile({
file: {
name: "Hello.txt",
data: blob
}
});
と Blob を指定した場合は問題ありません。
関係のあると思われるソースコード箇所
https://github.com/kintone/js-sdk/blob/master/packages/rest-api-client/src/client/FileClient.ts#L41
kintone-cli を使用して TypeScript で カスタマイズを実装しています。
"dependencies": {
"@kintone/kintone-ui-component": "^0.6.0",
"@kintone/rest-api-client": "^1.2.0",
"react": "^16.8.6",
"react-dom": "^16.7.0"
},
"devDependencies": {
"local-web-server": "^2.6.1",
"webpack": "^4.30.0",
"webpack-cli": "^3.2.3",
"babel-loader": "^8.0.5",
"style-loader": "^0.23.1",
"css-loader": "^2.1.0",
"core-js": "^3.2.1",
"regenerator-runtime": "^0.13.3",
"@babel/core": "^7.3.3",
"@babel/preset-env": "^7.3.1",
"@babel/plugin-proposal-class-properties": "^7.3.3",
"@babel/plugin-syntax-dynamic-import": "^7.2.0",
"@babel/preset-typescript": "^7.3.3",
"@babel/preset-react": "^7.0.0",
"typescript": "^3.6.3",
"@types/react": "^16.8.16",
"@types/react-dom": "^16.8.4",
"@kintone/customize-uploader": "^2.0.5",
"eslint": "^6.5.1",
"@cybozu/eslint-config": ">=7.1.0"
},
Currently, Renovate doesn't seem to manage dependencies of packages in examples
directory.
For example, this PR should update ts-node
in rest-api-client-demo
as well.
#211
ref. #65
When retrieving records with query,
クエリ検索結果が10万件以上存在するとき、絞り込みが中断されます。
その場合レスポンスヘッダに「x-cybozu-warning : Filter aborted because of too many search results.」が追加されます。
We need to support this header or other ways for users to know this warning.
Currently, we can't detect #176 because we don't have a test for this, so I have to add a test to be able to detect this.
code completion on record.updateAllRecords()
is not correct.
Some methods have the same issue, for example; updateRecords()
, updateRecordAssignees()
, deleteRecords()
, deleteAllRecords()
, deleteRecordComment()
, and so on.
They should be RecordID
and RevisionID
.
Kintone has OAuth access token support, but rest-api-client
doesn't support yet.
So we want rest-api-client
to accept OAuth access token.
ref. #64
This PR make rest-api-token
to be able to accept OAuth token at its constructor.
// This interface hasn't fixed so we might change the interface
const client = new KintoneRestAPIClient({
baseUrl: "https://example.cybozu.com",
auth: {
oauthToken: process.env.KINTONE_OAUTH_TOKEN
}
});
ref. kintone/js-sdk-ja#8
In https://developer.kintone.io/hc/en-us/articles/212495188 (en) or https://developer.cybozu.io/hc/ja/articles/201941754#step10 (ja)
We should offer the way to know running concurrent API requests.
BulkRequest のパラメータ requests[].api で APIのパスを指定する際に必要になるため
buildPathWithGuestSpaceId メソッドを public に使えるようにして欲しい。
※ buildPathWithGuestSpaceId メソッドが public でないため独自実装している例
https://github.com/r3-yamauchi/kintone-delete-by-cursor/blob/master/src/BulkDel.ts#L48
https://github.com/r3-yamauchi/kintone-delete-by-cursor/blob/master/src/Util.ts#L86
249164c#diff-0c5d15aae00d4d9c3cb6465b57d756aaR301
のように SDK内で内部的に BulkRequest している場合はよいが、BulkRequest を実行する実装を自分で書く場合もあるため
all packages
Node.js v14 is the recommended version for most users, so we should run tests on CI with the version.
After the Kintone's next update on July 2021, new format version become available like '1.2.3'.
modify packages/plugin-manifest-validator/manifest-schema.json
to accept new format.
https://www.typescriptlang.org/docs/handbook/project-references.html
Currently, we compile TypeScript each package separately, which is not a problem now, but it might be a problem in the future we've had many packages in this repository.
I guess that TypeScript Project References solves the problem., so it's great to investigate it.
@kintone/[email protected]
or laterCurrently
$ npm install -g @kintone/plugin-uploader
$ kintone-plugin-uploader <path-to-plugin-file>
Open https://xxx.cybozu.com/login?saml=off
Trying to log in...
Navigate to https://xxx.cybozu.com/k/admin/system/plugin/
Trying to upload SAMPLE_text_connet_plugin_v1.3.4.zip
エラーが発生しました TimeoutError: waiting for selector `.ocean-ui-dialog` to be hidden failed: timeout 60000ms exceeded
at new WaitTask (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:509:34)
at DOMWorld.waitForSelectorInPage (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:420:26)
at Object.internalHandler.waitFor (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/QueryHandler.js:31:77)
at DOMWorld.waitForSelector (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/DOMWorld.js:313:29)
at Frame.waitForSelector (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/FrameManager.js:841:51)
at Page.waitForSelector (/Users/***/node_modules/puppeteer/lib/cjs/puppeteer/common/Page.js:1333:33)
at /Users/***/node_modules/@kintone/plugin-uploader/dist/index.js:83:20
at Generator.next (<anonymous>)
at fulfilled (/Users/***/node_modules/@kintone/plugin-uploader/dist/index.js:5:58)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
✨ Done in 65.09s.
Can successfully upload the plugin.
Use @kintone/[email protected]
.
The current limitation of addRecords
(limited until 100 records) is inconvenient so we'd like to add a method to be able to exceed the limitation.
This method is to be able to add over 100 records to an app.
Here is the interface we plan.
const results = await this.client.record.addAllRecords({
app: APP_ID,
records
});
This plan is a roadmap for the next few months.
We focus on supporting all features that kintone-js-sdk has.
uploadFile()
method (#115)🏃 ... work in progress
🤔 ... under discussion
✋ ... postpone
@kintone/plugin-uploader
@chick-p
KINTONE_BASE_URL
#534@kintone/customize-uploader
@chick-p
@kintone/dts-gen
@koba04 (@potaracom)
KINTONE_DOMAIN
, which includes domain
option as well @chick-p
host
, proxyHost
, and proxyPort
option
@kintone/dts-gen
#869@kintone/[email protected]
@kintone/[email protected]
@kintone/[email protected]
(No CHANGELOG)Currently, those packages have some environment variables support like KINTONE_USERNAME
and KINTONE_API_TOKEN
, which is useful but the support has some inconsistency like kintone/js-sdk-ja#7 (comment) (Thank you @potaracom)
The inconsistency is cumbersome for developers who use these packages.
So we'd like to address the issue.
We will unify the usage of environment variables like the following.
KINTONE_USERNAME
... Your user nameKINTONE_PASSWORD
... Your passwordKINTONE_BASE_URL
... The URL of your Kintone environment e.g. https://example.kintone.comKINTONE_API_TOKEN
... API TokenKINTONE_OAUTH_TOKEN
... OAuth TokenKINTONE_BASIC_AUTH_USERNAME
... The user name of Basic AuthenticationKINTONE_BASIC_AUTH_PASSWORD
... The password of Basic AuthenticationHTTP_PROXY
... The URL of HTTP proxy serverHTTPS_PROXY
... The URL of HTTPS proxy serverplugin-uploader | customize-uploader | dts-gen | |
---|---|---|---|
KINTONE_USERNAME | 🙆♀️ | 🙆♀️ | 🚀 |
KINTONE_PASSWORD | 🙆♀️ | 🙆♀️ | 🚀 |
KINTONE_BASE_URL | 🚀 | 🚀 | 🚀 |
KINTONE_API_TOKEN | ⛔ | ⛔ | 🚀 |
KINTONE_OAUTH_TOKEN | ⛔ | 🚀 | 🚀 |
KINTONE_DOMAIN | 🙅 | 🙅 | ⛔ |
KINTONE_BASIC_AUTH_USERNAME | 🙆♀️ | 🙆♀️ | 🚀 |
KINTONE_BASIC_AUTH_PASSWORD | 🙆♀️ | 🙆♀️ | 🚀 |
HTTP_PROXY | 🙆♀️ | 🙆♀️ | 🚀 |
HTTPS_PROXY | 🙆♀️ | 🙆♀️ | 🚀 |
KINTONE_DOMAIN
, which includes domain
option as well.packages in js-sdk
are intended to be written by TypeScript, but plugin-manifest-validator is not.
Migrate plugin-manifest-validator to TypeScript.
related to #622
When invalid guestSpaceId
is given, rest-api-client generates invalid request url and causes runtime error.
validate guestSpaceId
parameter.
Currently, file.uploadFile() supports only file data and we can't pass its path.
It would be more convenient if it also accepts the path of the file.
NOTE: This feature is available only in Node.js environment.
// We haven't fixed the interface yet.
const client = new KintoneRestAPIClient({ ... });
const result = await this.client.file.uploadFile({
file: 'PATH_TO_FILE' // or separate parameter name?
})
There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.
Error type: Cannot find preset's package (prConcurrentLimitNone)
We'd like to support the situation that we add a record but update an existing record if the record has already been registered.
This method updates or inserts details of 1 record in an app. this updates a record if the unique key specifying by uniqueKey has matched any record, otherwise inserts a record.
const result = await this.client.record.upsertRecord({
app: APP_ID,
updateKey: {
field,
value,
},
record,
})
I generated type definition of SUBTABLE field.
The type
and value.id
properties are required, which makes them difficult to use.
Table: {
type: 'SUBTABLE';
value: {
id: string;
value: {
text1: kintone.fieldTypes.SingleLineText;
text2: kintone.fieldTypes.SingleLineText;
};
}[];
};
I wish the type
and value.id
properties were no longer required.
Table: {
type?: 'SUBTABLE';
value: {
id?: string;
value: {
text1: kintone.fieldTypes.SingleLineText;
text2: kintone.fieldTypes.SingleLineText;
};
}[];
};
Currently, data-loader
prints the actual values of each environment variables in help messages.
Those variables often include sensitive values like a password, so I think we shouldn't print the actual values in the help message.
I haven't confirmed whether yargs
has a proper way to fix this or not, so the Expected Behavior
section might be changed.
***
is the actual values I've set as environment variables.
オプション:
--version バージョンを表示 [真偽]
--help ヘルプを表示 [真偽]
--base-url Kintone Base Url
[デフォルト: "https://***.cybozu.com/"]
--username, -u Kintone Username [デフォルト: "***"]
--password, -p Kintone Password [デフォルト: "***"]
--api-token App's API token
--basic-auth-username Kintone Basic Auth Username
--basic-auth-password Kintone Basic Auth Password
--app The ID of the app
--guest-space-id The ID of guest space
--file-path file path
--pfx-file-path The path to client certificate file
--pfx-file-password The password of client certificate file
***
is the actual values I've set as environment variables.
オプション:
--version バージョンを表示 [真偽]
--help ヘルプを表示 [真偽]
--base-url Kintone Base Url
[デフォルト: KINTONE_BASE_URL]
--username, -u Kintone Username [デフォルト: KINTONE_USER_NAME]
--password, -p Kintone Password [デフォルト: KINTONE_PASSWORD]
--api-token App's API token
--basic-auth-username Kintone Basic Auth Username
--basic-auth-password Kintone Basic Auth Password
--app The ID of the app
--guest-space-id The ID of guest space
--file-path file path
--pfx-file-path The path to client certificate file
--pfx-file-password The password of client certificate file
Some methods rest-api-client
provides accept a type parameter for a type definition of your app.
type MyAppRecord = { /* ... */ }
// the type of the record will be MyAppRecord
const record = client.record.getRecord<MyAppRecord>({ app: 1, id: 10 })
After #404 has been merged, we could define the type definition using types #404 exposes.
But it's a bit cumbersome because we have to define the type definition manually.
dts-gen
provides us a command to be able to generate type definitions for your app.
But the type definition dts-gen
generates is not compatible with rest-api-client
expects (refs. #442).
We'd like to provide a way to generate type definitions, which are compatible with rest-api-client
, automatically.
We could take some options to fix the issue.
rest-api-client
into dts-gen
.rest-api-client
.Now, we have several types for a Kintone record type like the following.
So we have to sort each type definition respectively.
rest-api-client
has a scripts
directory that has scripts that are for testing and examples.
Currently, there are dependencies and npm-scripts only for the scripts in rest-api-client
package.
I think it would be nice if the scripts are placed as a separate package.
It isn't an npm package, so it would be nice if the package is put into like examples/
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.