{"openapi":"3.1.0","info":{"title":"data.gov.sg (BYOK) API","version":"0.1.0","description":"data.gov.sg (BYOK) lets an AI assistant read your own data.gov.sg data through the data.gov.sg API with a key you supply (data.gov.sg API key). Read-only: 5 tools (list_collections, get_collection, list_datasets, get_dataset_metadata, list_dataset_rows). The BYOK key travels with each request, is used for that one call only and is never stored, logged or cached; it is only ever sent to...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-datagovsg.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-datagovsg/docs"},"termsOfService":"https://connectorbay.com/byok-datagovsg/terms"},"servers":[{"url":"https://byok-datagovsg.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-datagovsg/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_collections":{"post":{"operationId":"list_collections","summary":"List data.gov.sg collections (themed groups of datasets) with name, description, coverage dates, update frequency, manag","description":"List data.gov.sg collections (themed groups of datasets) with name, description, coverage dates, update frequency, managing agency and child dataset ids. Use for \"Which collections are published on data.gov.sg\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"page":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Page number, starting at 1; the answer reports the total number of pages.","title":"Page"}},"title":"list_collectionsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_collection":{"post":{"operationId":"get_collection","summary":"Get one collection's metadata, optionally including the metadata of every dataset inside it. Use for \"Show collection 52","description":"Get one collection's metadata, optionally including the metadata of every dataset inside it. Use for \"Show collection 522 on data.gov.sg with its datasets\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"collection_id":{"description":"Numeric collection id, for example 522 (from list_collections or the collection page URL).","minimum":1,"title":"Collection Id","type":"integer"},"with_dataset_metadata":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":true,"description":"True to include the metadata of the datasets in the collection.","title":"With Dataset Metadata"}},"required":["collection_id"],"title":"get_collectionArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_datasets":{"post":{"operationId":"list_datasets","summary":"List datasets on data.gov.sg with id, name, format, status, managing agency, coverage dates and last update time. Use fo","description":"List datasets on data.gov.sg with id, name, format, status, managing agency, coverage dates and last update time. Use for \"List the datasets available on data.gov.sg\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"page":{"anyOf":[{"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Page number, starting at 1; the answer reports the total number of pages.","title":"Page"}},"title":"list_datasetsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_dataset_metadata":{"post":{"operationId":"get_dataset_metadata","summary":"Get one dataset's metadata: name, format, managing agency, coverage dates and the column names, titles and data types. U","description":"Get one dataset's metadata: name, format, managing agency, coverage dates and the column names, titles and data types. Use for \"What columns does data.gov.sg dataset d_11e68bba3b3c76733475a72d09759eeb have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"dataset_id":{"description":"Dataset id such as d_11e68bba3b3c76733475a72d09759eeb (shown in the dataset page URL on data.gov.sg, or from list_datasets).","maxLength":80,"title":"Dataset Id","type":"string"}},"required":["dataset_id"],"title":"get_dataset_metadataArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_dataset_rows":{"post":{"operationId":"list_dataset_rows","summary":"Read the first page of rows of a tabular dataset; the answer includes the page size and a link for the next page when mo","description":"Read the first page of rows of a tabular dataset; the answer includes the page size and a link for the next page when more rows exist. Use for \"Show the first rows of data.gov.sg dataset d_11e68bba3b3c76733475a72d09759eeb\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"dataset_id":{"description":"Dataset id such as d_11e68bba3b3c76733475a72d09759eeb (shown in the dataset page URL on data.gov.sg, or from list_datasets).","maxLength":80,"title":"Dataset Id","type":"string"}},"required":["dataset_id"],"title":"list_dataset_rowsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}