1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-04-25 12:24:39 +02:00

114 lines
2.2 KiB
Markdown
Raw Normal View History

---
sidebar_position: 2
---
# Modify table
Changes the name and/or description of the base
2024-07-10 13:58:29 +03:00
`Function ModifyTable(Val Token, Val Base, Val Table, Val Name = "", Val Description = "") Export`
| Parameter | CLI option | Type | Description |
|-|-|-|-|
| Token | --token | String | Token |
| Base | --base | String | Base identifier |
| Table | --table | String | Table identifier |
| Name | --title | String | New name |
| Description | --description | String | New description |
Returns: Map Of KeyAndValue - serialized JSON response from Airtable
2024-07-10 14:05:58 +03:00
<br/>
2024-07-10 13:58:29 +03:00
```bsl title="Code example"
2024-10-02 20:28:02 +03:00
Token = "patNn4BXW66Yx3pdj.5b93c53cab554a8387de02d...";
2024-10-15 10:07:27 +03:00
Base = "appESy99HYCLbuWlV";
Table = "tbl5gZLQ8i5xKuVTy";
2024-10-02 20:28:02 +03:00
Name = "Test table 2 (change.)";
Description = "New table (change.)";
Result = OPI_Airtable.ModifyTable(Token, Base, Table, Name, Description);
```
2024-10-15 09:53:37 +03:00
```json title="Result"
2024-10-03 09:45:14 +03:00
{
2024-10-09 09:42:00 +03:00
"id": "tbl1ECxOLd4V6OM9T",
2024-10-03 09:45:14 +03:00
"name": "Test table 2 (change.)",
"description": "New table (change.)",
2024-10-09 09:42:00 +03:00
"primaryFieldId": "fldhWwOjg9UhvJ6A2",
2024-10-03 09:45:14 +03:00
"fields": [
{
2024-10-09 09:42:00 +03:00
"id": "fldhWwOjg9UhvJ6A2",
2024-10-03 09:45:14 +03:00
"name": "Number",
"type": "number",
"options": {
"precision": 0
}
},
{
2024-10-09 09:42:00 +03:00
"id": "fld8KaCe62SjwSYAk",
2024-10-03 09:45:14 +03:00
"name": "String",
"type": "richText"
},
{
2024-10-09 09:42:00 +03:00
"id": "fldSWB4hUUyP5Hx30",
2024-10-03 09:45:14 +03:00
"name": "Attachment",
"type": "multipleAttachments",
"options": {
"isReversed": false
}
},
{
2024-10-09 09:42:00 +03:00
"id": "fld7UipYF2w9FsoRm",
2024-10-03 09:45:14 +03:00
"name": "Checkbox",
"type": "checkbox",
"options": {
"icon": "check",
"color": "yellowBright"
}
},
{
2024-10-09 09:42:00 +03:00
"id": "fldHVbDsv6ndNp2XZ",
2024-10-03 09:45:14 +03:00
"name": "Date",
"type": "date",
"options": {
"dateFormat": {
"name": "iso",
"format": "YYYY-MM-DD"
}
}
},
{
2024-10-09 09:42:00 +03:00
"id": "fldYL0IFRMVQCO7gW",
2024-10-03 09:45:14 +03:00
"name": "Phone",
"type": "phoneNumber"
},
{
2024-10-09 09:42:00 +03:00
"id": "fldzsmOGCGjThDsUp",
2024-10-03 09:45:14 +03:00
"name": "Email",
"type": "email"
},
{
2024-10-09 09:42:00 +03:00
"id": "fldMWVcVuR9CmKBcD",
2024-10-03 09:45:14 +03:00
"name": "Link",
"type": "url"
}
],
"views": [
{
2024-10-09 09:42:00 +03:00
"id": "viwMlZ7T3KyjEufmW",
2024-10-03 09:45:14 +03:00
"name": "Grid view",
"type": "grid"
}
]
}
```