nextcloud / nextcloud/tables

/columns API endpoint returns undefined for name, options, and required fields, breaking row insertions via API

Open
#1,984 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug feature: api
Dominant language
JavaScript
Stars
214
Forks
52
Avg merge
1d 10h
Merged PRs (30d)
82

Description

Describe the bug:

The /columns endpoint of the Nextcloud Tables API is returning incomplete metadata for all columns in my table. Specifically, every column shows:

"name": undefined
"required": undefined
"options": [] (even for selection fields with options)

As a result, attempts to insert rows via the API consistently fail with HTTP 500 and the message: Could not create row.
This issue occurs even though:
All columns in the GUI are correctly named.
Column types (text, selection, datetime) and options are clearly visible and editable via the UI.
Columns have been made optional and edited to ensure they save correctly.

To Reproduce:

Create a table in Nextcloud Tables with various column types.
Use the /columns API endpoint to inspect column metadata.
Attempt to insert rows via the API using valid column IDs and values.
Observe HTTP 500 errors and incomplete column metadata.

Expected behavior:

The /columns endpoint should return correct names, required flags, and selection options.
Row insertions should succeed if valid data is provided.

sudo node inspect-columns.mjs
[dotenv@17.2.1] injecting env (4) from .env -- tip: βš™οΈ specify custom .env file path with { path: '/custom/path/.env' }
πŸ“‹ Columns (22 total):
πŸ†” ID: 235
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 236
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 237
Name: undefined
Type: datetime
Required: undefined
Options: []

πŸ†” ID: 238
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 239
Name: undefined
Type: datetime
Required: undefined
Options: []

πŸ†” ID: 240
Name: undefined
Type: datetime
Required: undefined
Options: []

πŸ†” ID: 241
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 242
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 243
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 244
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 245
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 246
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 247
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 248
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 249
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 250
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 251
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 252
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 253
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 254
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 255
Name: undefined
Type: text
Required: undefined
Options: []

πŸ†” ID: 256
Name: undefined
Type: text
Required: undefined
Options: []

Nextcloud Hub 10 (31.0.7), Tables
Version 0.9.5, AGPL-licensed, Ubuntu 24,

When trying to sync Tables with the Forms .csv
❌ HTTP 500 while inserting row #1
πŸ“€ Payload Sent: {"213":"Travis Harper","214":"2025-08-06T00:00:00Z","215":"1970-01-01T15:10:00Z","218":"Harper","219":"Travis"}
πŸ“₯ Response: {"message":"Could not create row."}
πŸ” Payload for row #2: {
"213": "Travis Harper",
"214": "2025-08-06T00:00:00Z",
"215": "1970-01-01T15:10:00Z",
"218": "Harper",
"219": "Travis"
}
❌ HTTP 500 while inserting row #2
πŸ“€ Payload Sent: {"213":"Travis Harper","214":"2025-08-06T00:00:00Z","215":"1970-01-01T15:10:00Z","218":"Harper","219":"Travis"}
πŸ“₯ Response: {"message":"Could not create row."}
πŸ” Sync complete. Total rows processed: 2, successful: 0
travis@PlexMediaServer:/opt/sbsl-sync$

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up β€” it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with inspect-columns.mjs and the /columns endpoint, then trace the row-insertion request that returns β€œCould not create row.” Compare the endpoint response with the table metadata shown in the GUI. Done means names, required flags, and selection options are returned correctly and valid row insertions no longer fail.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
api, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.