You need to sign in or sign up before continuing.
Newer
Older
## `GET /api/activity/`
Get recent activity.
## `GET /api/activity/recent_views`
Get the list of 10 things the current user has been viewing most recently.
Delete an Alert. (DEPRECATED -- don't delete a Alert anymore -- archive it instead.)
##### PARAMS:
* **`archived`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
## `GET /api/alert/question/:id`
Fetch all questions for the given question (`Card`) id
##### PARAMS:
##### PARAMS:
* **`alert_condition`** value must be one of: `goal`, `rows`.
* **`card`** value must be a map with the keys `id`, `include_csv`, and `include_xls`.
* **`channels`** value must be an array. Each value must be a map. The array cannot be empty.
* **`alert_first_only`** value must be a boolean.
* **`alert_above_goal`** value may be nil, or if non-nil, value must be a boolean.
## `PUT /api/alert/:id`
Update a `Alert` with ID.
##### PARAMS:
* **`alert_condition`** value may be nil, or if non-nil, value must be one of: `goal`, `rows`.
* **`card`** value may be nil, or if non-nil, value must be a map with the keys `id`, `include_csv`, and `include_xls`.
* **`channels`** value may be nil, or if non-nil, value must be an array. Each value must be a map. The array cannot be empty.
* **`alert_first_only`** value may be nil, or if non-nil, value must be a boolean.
* **`alert_above_goal`** value may be nil, or if non-nil, value must be a boolean.
* **`archived`** value may be nil, or if non-nil, value must be a boolean.
## `PUT /api/alert/:id/unsubscribe`
Unsubscribes a user from the given alert
##### PARAMS:
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query`
Return an automagic dashboard for entity `entity` with id `ìd`.
* **`show`** invalid show value
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/cell/:cell-query`
Return an automagic dashboard analyzing cell in automagic dashboard for entity `entity`
defined by
query `cell-querry`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`cell-query`** value couldn't be parsed as base64 encoded JSON
* **`show`** invalid show value
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/cell/:cell-query/compare/:comparison-entity/:comparison-entity-id-or-query`
Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`
with id `ìd` defined by query `cell-querry`; compared with entity `comparison-entity` with id
`comparison-entity-id-or-query.`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`cell-query`** value couldn't be parsed as base64 encoded JSON
* **`show`** invalid show value
* **`comparison-entity`** Invalid comparison entity type. Can only be one of "table", "segment", or "adhoc"
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/cell/:cell-query/rule/:prefix/:rule`
Return an automagic dashboard analyzing cell in question with id `id` defined by
query `cell-querry` using rule `rule`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`cell-query`** value couldn't be parsed as base64 encoded JSON
* **`prefix`** invalid value for prefix
* **`rule`** invalid value for rule name
* **`show`** invalid show value
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/cell/:cell-query/rule/:prefix/:rule/compare/:comparison-entity/:comparison-entity-id-or-query`
Return an automagic comparison dashboard for cell in automagic dashboard for entity `entity`
with id `ìd` defined by query `cell-querry` using rule `rule`; compared with entity
`comparison-entity` with id `comparison-entity-id-or-query.`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`cell-query`** value couldn't be parsed as base64 encoded JSON
* **`prefix`** invalid value for prefix
* **`rule`** invalid value for rule name
* **`show`** invalid show value
* **`comparison-entity`** Invalid comparison entity type. Can only be one of "table", "segment", or "adhoc"
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/compare/:comparison-entity/:comparison-entity-id-or-query`
Return an automagic comparison dashboard for entity `entity` with id `ìd` compared with entity
`comparison-entity` with id `comparison-entity-id-or-query.`
##### PARAMS:
* **`entity`** Invalid entity type
* **`comparison-entity`** Invalid comparison entity type. Can only be one of "table", "segment", or "adhoc"
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/rule/:prefix/:rule`
Return an automagic dashboard for entity `entity` with id `ìd` using rule `rule`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`prefix`** invalid value for prefix
* **`rule`** invalid value for rule name
* **`show`** invalid show value
## `GET /api/automagic-dashboards/:entity/:entity-id-or-query/rule/:prefix/:rule/compare/:comparison-entity/:comparison-entity-id-or-query`
Return an automagic comparison dashboard for entity `entity` with id `ìd` using rule `rule`;
compared with entity `comparison-entity` with id `comparison-entity-id-or-query.`.
##### PARAMS:
* **`entity`** Invalid entity type
* **`prefix`** invalid value for prefix
* **`rule`** invalid value for rule name
* **`show`** invalid show value
* **`comparison-entity`** Invalid comparison entity type. Can only be one of "table", "segment", or "adhoc"
## `GET /api/automagic-dashboards/database/:id/candidates`
Return a list of candidates for automagic dashboards orderd by interestingness.
##### PARAMS:
## `DELETE /api/card/:card-id/favorite`
Unfavorite a Card.
##### PARAMS:
## `DELETE /api/card/:card-id/public_link`
You must be a superuser to do this.
##### PARAMS:
Delete a Card. (DEPRECATED -- don't delete a Card anymore -- archive it instead.)
## `GET /api/card/`
Get all the Cards. Option filter param `f` can be used to change the set of Cards that are returned; default is
`all`, but other options include `mine`, `fav`, `database`, `table`, `recent`, `popular`, and `archived`. See
corresponding implementation functions above for the specific behavior of each filter option. :card_index:
* **`f`** value may be nil, or if non-nil, value must be one of: `all`, `archived`, `database`, `fav`, `mine`, `popular`, `recent`, `table`.
* **`model_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
## `GET /api/card/:id`
Get `Card` with ID.
##### PARAMS:
## `GET /api/card/:id/related`
Return related entities.
##### PARAMS:
Fetch a list of Cards where `enable_embedding` is `true`. The cards can be embedded using the embedding endpoints
and a signed JWT.
You must be a superuser to do this.
## `GET /api/card/public`
Fetch a list of Cards with public UUIDs. These cards are publicly-accessible *if* public sharing is enabled.
You must be a superuser to do this.
## `POST /api/card/`
Create a new `Card`.
##### PARAMS:
* **`visualization_settings`** value must be a map.
* **`description`** value may be nil, or if non-nil, value must be a non-blank string.
* **`collection_position`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`result_metadata`** value may be nil, or if non-nil, value must be an array of valid results column metadata maps.
* **`metadata_checksum`** value may be nil, or if non-nil, value must be a non-blank string.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
Generate publicly-accessible links for this Card. Returns UUID to be used in public links. (If this Card has
already been shared, it will return the existing public link rather than creating a new one.) Public sharing must
be enabled.
You must be a superuser to do this.
##### PARAMS:
## `POST /api/card/:card-id/query`
Run the query associated with a Card.
##### PARAMS:
* **`ignore_cache`** value may be nil, or if non-nil, value must be a boolean.
## `POST /api/card/:card-id/query/:export-format`
Run the query associated with a Card, and return its results as a file in the specified format. Note that this
expects the parameters as serialized JSON in the 'parameters' parameter
* **`export-format`** value must be one of: `csv`, `json`, `xlsx`.
* **`parameters`** value may be nil, or if non-nil, value must be a valid JSON string.
## `POST /api/card/collections`
Bulk update endpoint for Card Collections. Move a set of `Cards` with CARD_IDS into a `Collection` with
COLLECTION_ID, or remove them from any Collections by passing a `null` COLLECTION_ID.
##### PARAMS:
* **`card_ids`** value must be an array. Each value must be an integer greater than zero.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
## `POST /api/card/related`
Return related entities for an ad-hoc query.
##### PARAMS:
## `PUT /api/card/:id`
Update a `Card`.
##### PARAMS:
* **`visualization_settings`** value may be nil, or if non-nil, value must be a map.
* **`description`** value may be nil, or if non-nil, value must be a string.
* **`archived`** value may be nil, or if non-nil, value must be a boolean.
* **`collection_position`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`result_metadata`** value may be nil, or if non-nil, value must be an array of valid results column metadata maps.
* **`metadata_checksum`** value may be nil, or if non-nil, value must be a non-blank string.
* **`enable_embedding`** value may be nil, or if non-nil, value must be a boolean.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`name`** value may be nil, or if non-nil, value must be a non-blank string.
* **`embedding_params`** value may be nil, or if non-nil, value must be a valid embedding params map.
* **`dataset_query`** value may be nil, or if non-nil, value must be a map.
* **`display`** value may be nil, or if non-nil, value must be a non-blank string.
Fetch a list of all Collections that the current user has read permissions for (`:can_write` is returned as an
additional property of each Collection so you can tell which of these you have write permissions for.)
By default, this returns non-archived Collections, but instead you can show archived ones by passing
`?archived=true`.
##### PARAMS:
* **`archived`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
Fetch a specific Collection with standard details added
##### PARAMS:
## `GET /api/collection/:id/items`
Fetch a specific Collection's items with the following options:
* `model` - only include objects of a specific `model`. If unspecified, returns objects of all models
* `archived` - when `true`, return archived objects *instead* of unarchived ones. Defaults to `false`.
* **`model`** value may be nil, or if non-nil, value must be one of: `card`, `collection`, `dashboard`, `pulse`.
* **`archived`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
## `GET /api/collection/graph`
Fetch a graph of all Collection Permissions.
## `GET /api/collection/root`
Return the 'Root' Collection object with standard details added
## `GET /api/collection/root/items`
Fetch objects that the current user should see at their root level. As mentioned elsewhere, the 'Root' Collection
doesn't actually exist as a row in the application DB: it's simply a virtual Collection where things with no
`collection_id` exist. It does, however, have its own set of Permissions.
This endpoint will actually show objects with no `collection_id` for Users that have Root Collection
permissions, but for people without Root Collection perms, we'll just show the objects that have an effective
location of `/`.
This endpoint is intended to power a 'Root Folder View' for the Current User, so regardless you'll see all the
top-level objects you're allowed to access.
##### PARAMS:
* **`model`** value may be nil, or if non-nil, value must be one of: `card`, `collection`, `dashboard`, `pulse`.
* **`archived`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
## `POST /api/collection/`
Create a new Collection.
##### PARAMS:
* **`name`** value must be a non-blank string.
* **`color`** value must be a string that matches the regex `^#[0-9A-Fa-f]{6}$`.
* **`description`** value may be nil, or if non-nil, value must be a non-blank string.
* **`parent_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
Modify an existing Collection, including archiving or unarchiving it, or moving it.
* **`name`** value may be nil, or if non-nil, value must be a non-blank string.
* **`color`** value may be nil, or if non-nil, value must be a string that matches the regex `^#[0-9A-Fa-f]{6}$`.
* **`description`** value may be nil, or if non-nil, value must be a non-blank string.
* **`archived`** value may be nil, or if non-nil, value must be a boolean.
* **`parent_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
## `PUT /api/collection/graph`
Do a batch update of Collections Permissions by passing in a modified graph.
##### PARAMS:
* **`body`** value must be a map.
## `DELETE /api/dashboard/:dashboard-id/public_link`
Delete the publicly-accessible link to this Dashboard.
You must be a superuser to do this.
##### PARAMS:
## `DELETE /api/dashboard/:id`
## `DELETE /api/dashboard/:id/cards`
* **`dashcardId`** value must be a valid integer greater than zero.
## `DELETE /api/dashboard/:id/favorite`
Unfavorite a Dashboard.
##### PARAMS:
## `GET /api/dashboard/`
Get `Dashboards`. With filter option `f` (default `all`), restrict results as follows:
* `all` - Return all Dashboards.
* `mine` - Return Dashboards created by the current user.
* `archived` - Return Dashboards that have been archived. (By default, these are *excluded*.)
* **`f`** value may be nil, or if non-nil, value must be one of: `all`, `archived`, `mine`.
## `GET /api/dashboard/:id`
## `GET /api/dashboard/:id/related`
Return related entities.
##### PARAMS:
## `GET /api/dashboard/:id/revisions`
## `GET /api/dashboard/embeddable`
Fetch a list of Dashboards where `enable_embedding` is `true`. The dashboards can be embedded using the embedding
endpoints and a signed JWT.
You must be a superuser to do this.
## `GET /api/dashboard/public`
Fetch a list of Dashboards with public UUIDs. These dashboards are publicly-accessible *if* public sharing is
enabled.
You must be a superuser to do this.
##### PARAMS:
* **`name`** value must be a non-blank string.
* **`description`** value may be nil, or if non-nil, value must be a string.
* **`parameters`** value must be an array. Each value must be a map.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`collection_position`** value may be nil, or if non-nil, value must be an integer greater than zero.
## `POST /api/dashboard/:dashboard-id/public_link`
Generate publicly-accessible links for this Dashboard. Returns UUID to be used in public links. (If this
Dashboard has already been shared, it will return the existing public link rather than creating a new one.) Public
sharing must be enabled.
You must be a superuser to do this.
##### PARAMS:
* **`dashboard-id`**
## `POST /api/dashboard/:from-dashboard-id/copy`
Copy a Dashboard.
##### PARAMS:
* **`from-dashboard-id`**
* **`name`** value may be nil, or if non-nil, value must be a non-blank string.
* **`description`** value may be nil, or if non-nil, value must be a string.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`collection_position`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`dashboard`**
## `POST /api/dashboard/:id/cards`
* **`cardId`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`parameter_mappings`** value must be an array. Each value must be a map.
## `POST /api/dashboard/:id/favorite`
Favorite a Dashboard.
##### PARAMS:
## `POST /api/dashboard/:id/revert`
* **`revision_id`** value must be an integer greater than zero.
## `POST /api/dashboard/save`
Save a denormalized description of dashboard.
##### PARAMS:
## `POST /api/dashboard/save/collection/:parent-collection-id`
Save a denormalized description of dashboard into collection with ID `:parent-collection-id`.
##### PARAMS:
## `PUT /api/dashboard/:id`
Usually, you just need write permissions for this Dashboard to do this (which means you have appropriate
permissions for the Cards belonging to this Dashboard), but to change the value of `enable_embedding` you must be a
superuser.
* **`parameters`** value may be nil, or if non-nil, value must be an array. Each value must be a map.
* **`points_of_interest`** value may be nil, or if non-nil, value must be a string.
* **`description`** value may be nil, or if non-nil, value must be a string.
* **`archived`** value may be nil, or if non-nil, value must be a boolean.
* **`collection_position`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`show_in_getting_started`** value may be nil, or if non-nil, value must be a boolean.
* **`enable_embedding`** value may be nil, or if non-nil, value must be a boolean.
* **`collection_id`** value may be nil, or if non-nil, value must be an integer greater than zero.
* **`name`** value may be nil, or if non-nil, value must be a non-blank string.
* **`caveats`** value may be nil, or if non-nil, value must be a string.
* **`embedding_params`** value may be nil, or if non-nil, value must be a valid embedding params map.
* **`position`** value may be nil, or if non-nil, value must be an integer greater than zero.
## `PUT /api/dashboard/:id/cards`
Update Cards on a Dashboard. Request body should have the form:
{:cards [{:id ...
:sizeX ...
:sizeY ...
:row ...
:col ...
:series [{:id 123
...}]} ...]}
##### PARAMS:
## `DELETE /api/database/:id`
Delete a `Database`.
##### PARAMS:
## `GET /api/database/`
Fetch all `Databases`. `include_tables` means we should hydrate the Tables belonging to each DB. `include_cards` here
means we should also include virtual Table entries for saved Questions, e.g. so we can easily use them as source
Tables in queries. Default for both is `false`.
* **`include_tables`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
* **`include_cards`** value may be nil, or if non-nil, value must be a valid boolean string ('true' or 'false').
## `GET /api/database/:id`
Get `Database` with ID.
##### PARAMS:
## `GET /api/database/:id/autocomplete_suggestions`
Return a list of autocomplete suggestions for a given PREFIX.
This is intened for use with the ACE Editor when the User is typing raw SQL.
Suggestions include matching `Tables` and `Fields` in this `Database`.
Tables are returned in the format `[table_name "Table"]`;
Fields are returned in the format `[field_name "table_name base_type special_type"]`
##### PARAMS:
* **`prefix`** value must be a non-blank string.
## `GET /api/database/:id/fields`
Get a list of all `Fields` in `Database`.
##### PARAMS:
## `GET /api/database/:id/idfields`
Get a list of all primary key `Fields` for `Database`.
##### PARAMS:
## `GET /api/database/:id/metadata`
Get metadata about a `Database`, including all of its `Tables` and `Fields`.
Returns DB, fields, and field values.
##### PARAMS:
## `GET /api/database/:id/schema/:schema`
Returns a list of tables for the given database `id` and `schema`
##### PARAMS:
## `GET /api/database/:id/schemas`
Returns a list of all the schemas found for the database `id`
##### PARAMS:
## `GET /api/database/:virtual-db/metadata`
Endpoint that provides metadata for the Saved Questions 'virtual' database. Used for fooling the frontend
and allowing it to treat the Saved Questions virtual DB just like any other database.
## `POST /api/database/`
Add a new `Database`.
You must be a superuser to do this.
##### PARAMS:
* **`name`** value must be a non-blank string.
* **`engine`** value must be a valid database engine.
* **`details`** value must be a map.
* **`is_full_sync`** value may be nil, or if non-nil, value must be a boolean.
* **`is_on_demand`** value may be nil, or if non-nil, value must be a boolean.
* **`schedules`** value may be nil, or if non-nil, value must be a valid map of schedule maps for a DB.
## `POST /api/database/:id/discard_values`
Discards all saved field values for this `Database`.
You must be a superuser to do this.
##### PARAMS:
## `POST /api/database/:id/rescan_values`
Trigger a manual scan of the field values for this `Database`.
You must be a superuser to do this.
##### PARAMS:
## `POST /api/database/:id/sync`
Update the metadata for this `Database`. This happens asynchronously.
##### PARAMS:
## `POST /api/database/:id/sync_schema`
Trigger a manual update of the schema metadata for this `Database`.
You must be a superuser to do this.