How to use

Home > Connect > kintone > How to use
Japanese may be displayed on some pages.
- 1. Add the Cloud BOT Connector to an app
- 2. Plug-in settings
- 3. How to run the connected BOT
- 4. Generate the API token
- 5. Register the webhook
- 6. Supplementary note
Add the Cloud BOT Connector to an app
1. Select "Plug-ins" from the App Settings screen.

2. Click "Add Plug-in", select the check box next to the Cloud BOT Connector, then click the "Add" button.


Plug-in settings
Connection settings
In order to use the Cloud BOT Connector, Cloud BOT account connection must be configured.
1. Click the cog mark (settings) for the Cloud BOT Connector.

2. Generate and paste the API token to the "API token" field on the setting.
>> Click here about how to generate the API token

3. Click the "Authorize" button.

4.Log in to Cloud BOT with an account to connect.
If you have already logged in to Cloud BOT, the account will be connected.

When the status changes from "Not authorized" to "Authorized", the process is complete.
Run settings
Configure the BOT’s run settings.
* You can set the run settings for multiple BOTs. Click "+ Add bot settings" to add the settings.

BOT to execute
Select the BOT to execute.
*It is necessary to publish the API of the target BOT on the Cloud BOT service.

Execution status storage destination
Select the destination to store the BOT’s execution status. You can see the execution status on the run screen.
You can select only a string (single line) field.
>>Refer to this page about status.
* If this item is not selected, you cannot see the BOT’s execution status (However you can run the BOT).

Execution timing
Select the timing to run the BOT.

- "Execute" button
The "Execute" button is placed on the record screen, and BOT is executed by clicking it.
- Webhook
Execute BOT under certain conditions.
Following conditions are available:
- When a record is added
- When a record is edited
- When a record is deleted
- When a comment is posted
- When a status is updated*
* You need to enable [process management] in the app settings.
Webhook registration is required to set these conditions.
>> Refer to this page about registering a webhook.
Option
You can set the following options.

- Check input values before execution
After clicking the [Execute] button, you will be prompted to confirm the input values before running the BOT.
- Open BOT browsing screen at runtime
Clicking the "Execute" button opens the BOT browsing screen. (The page will open in a separate window)
BOT input values settings
Specify the input values assigned to the BOT.


Form values
Specifies the fields of kintone app.
>> Refer to this page for Cloud BOT’s data types to kintone’s field types mapping
Properties
Specifies the properties of kintone app.
- Comment
- Posted by
- Comment number
- Status
- Record number
- Updated by
- Updated datetime
- Author
- Created datetime
- Execution timing
Others
You can specify other values.
- Not entered
- Fixed value
* Input a value directly for “Fixed value”.

BOT output value storage destination setting
Select the BOT output value to be stored in the kintone app field.
*Any number of storage destinations can be set. Click "+ Add storage destination" to add the settings.

Storage destination

- Same record
Store the output value in the same record.

- New record
Create a new record and store the output value in to it. Select the app to which create a new record.
Filter by space and select an app.

Number of records to add
Specify this when the storage destination is set to "New record".
- 1 record
Create a new record for 1 record.

- Group data rows
Create records for group lines.

Destination field and stored value
Any number of storage destination fields can be set. Click "+ Add a field" to add the settings.

kintone app field
Specify the destination field.
BOT output data
Specify the value to be stored.
Output data
You can specify the output values when BOT is executed.
>> Refer to this page for Cloud BOT’s data types to kintone’s field types mapping.
* If "Group data rows" is selected in the "Number of records to add" item, only group data can be selected as BOT output data.
Others
You can specify other values.
- Fixed value
- Status
- BOT name
- Job ID
*Specify a value directly for “Fixed value”.
Input another API token
If another application is specified as the storage destination, an API token for each application is required.
Specify an API token for each application.
>>Refer to this page
this page about generating the API token.

Save / Update plug-in settings
1. After setting, click the "Save" button.

Click the "Update App" button to reflect the settings to the operational environment.

How to run the connected BOT

Execute button
Clicking the "Execute" button executes the BOT any time.

Check input values before execution
By selecting [Check input values before execution] in the options of Execute settings, a confirmation dialog will be displayed before the BOT run.

Open BOT browsing screen at runtime
By selecting [Open BOT browsing screen at runtime] in the run setting option, the preview of the run screen will open in a separate window.
Run with a webhook
The conditions under which the BOT is executed are displayed.
- added: When a record is added
- edited: When a record is edited
- deleted: When a record is deleted
- commented: When a comment is posted
- status updated: When a status is updated

Status
The execution status is displayed. Click the report icon next to the status to open the Cloud BOT execution logs screen in a separate window.

The status changes as follows.
Status when the BOT execution starts

Status when the BOT execution

Generate the API token
1. Go to the API token page from the link under the "API token" column in the connection settings.

2. Click the "Generate" button. "View records", "Add records", and "Edit records” access rights are required.

Be careful not to let others know the generated API token.
3. Click "Save" on the top left. The API token settings are saved.

4.Click the "Update App" button to reflect the settings to the operational environment.
Register the webhook
By registering a webhook, you can run the BOT when a specific event occurs.
1. Select "Webhook" on the "Execution settings" in the Cloud BOT Connector settings screen. Webhook URL is displayed.

2.Copy the webhook URL then click the webhook registration page link.

3.A separate window is open. Click [+] at the top right to add the webhook.

4.A separate window is open. Paste the copied URL in the "Webhook Endpoint" field.

5.Specify all "Events".

6. Finally, select [Activate this webhook] and click the [Save] button to register the webhook.

Supplementary note
Cloud BOT’s data types to kintone’s field types mapping
Cloud BOT’s data type | Kintone’s field type |
Text | Text |
Text area | |
Number | |
Rich text | |
Drop-down | |
Radio button | |
Date | |
Date and time | |
Time | |
Multiple texts | Multi-choice |
Check box | |
File | Attachment |
Group | Table |
Execution timing restrictions
If the following conditions are met at execution timing, the input value to the kintone app field will be "not specified".
Input value | Execution timing | Process administration settings |
All form field values | After deleting a record | - |
Comment | "Execute" button When a record is added When a record is edited When a record is deleted When a status is updated | - |
Posted by | "Execute" button When a record is added When a record is edited When a record is deleted When a status is updated | - |
Comment number | "Execute" button When a record is added When a record is edited When a record is deleted When a status is updated | - |
Status | - | Disabled |
Status | After deleting a record | - |