collections table in the database.
Board object
Unique Convex document ID for the board.
Timestamp (ms since epoch) when the board was created.
Display name of the board.
ID of the user who owns this board.
Whether the board is publicly visible. Defaults to
false.Ordered list of image IDs in this board.
Optional description of the board.
Queries
api.boards.list
Return all boards owned by the authenticated user, newest first.
No arguments. Requires authentication.
Returns Board[] — array of board objects without hydrated image data.
api.boards.getById
Fetch a single board with its images fully hydrated.
ID of the board to fetch.
Full image objects for each ID in
imageIds, with isLiked populated for the authenticated user. Deleted images are omitted.Returns an error if the board does not exist or is not owned by the authenticated user.
api.boards.getBoardImages
Fetch only the images for a board, without the board metadata.
ID of the board.
Image[] — image objects with isLiked populated. Deleted images are omitted.
api.boards.getBoardPreviewUrls
Fetch preview image URLs for multiple boards in one call. Useful for rendering board thumbnail grids.
Array of board IDs to fetch preview URLs for.
Maximum number of preview URLs to return per board.
Record<string, string[]> — an object keyed by board ID, where each value is an array of image URLs. For each image, the URL is chosen in priority order: previewUrl → derivativeUrls.medium → derivativeUrls.small → derivativeUrls.large → imageUrl.
Boards that are not found or not owned by the authenticated user are omitted from the result.
Mutations
api.boards.create
Create a new board.
Display name for the board.
Optional description.
Whether the board should be public.
Id<'collections'> — the ID of the created board.
api.boards.addImage
Add an image to a board.
ID of the board to add the image to.
ID of the image to add.
true when the image was added.Returns an error if the image is already in the board.
api.boards.removeImage
Remove an image from a board.
ID of the board.
ID of the image to remove.
true when the image was removed.api.boards.update
Update board metadata. Only fields provided are changed.
ID of the board to update.
New display name.
New description.
New visibility setting.
true when the board was updated.api.boards.deleteBoard
Permanently delete a board. Images referenced by the board are not deleted.
ID of the board to delete.
true when the board was deleted.