The Qiita API system is composed by 2 modules.

Qiita Plugin REST API

This module allows new plugins to get access, create and update data within Qiita. Note that some of these endpoints are required to follow RFC6750 and pass a payload to the methods, the rest follow the general format for GET/POST. A payload has 3 main components: 'success': True/False, 'step': <str>, and 'values': <dict>; the important parts of the values are described in the Parameters column.

Action URI Parameters Description Object Name
POST /qiita_db/authenticate/ grant_type : 'client', client_id : str, secret : str Authenticate given information as per RFC6750 TokenAuthHandler
POST /qiita_db/jobs/<job_id>/heartbeat/   Update the heartbeat timestamp of the job HeartbeatHandler
POST /qiita_db/jobs/<job_id>/step/ payload['step'] Changes the current execution step of the given job ActiveStepHandler
POST /qiita_db/jobs/<job_id>/complete/ payload['values']: { 'job_id': <job_id>, 'error': <str>, 'artifacts': <artifact_ids> } Updates the job to one of the completed statuses: ‘success’, ‘error’ CompleteHandler
GET /qiita_db/jobs/<job_id>   Get the job information JobHandler
POST /qiita_db/artifacts/types/ name: str, description: str, can_be_submitted_to_ebi: bool, can_be_submitted_to_vamps: bool, is_user_uploadable: bool, filepath_types: list (str, bool) Creates a new artifact type ArtifactTypeHandler
GET /qiita_db/artifacts/<artifact_id>/   Retrieves the artifact information ArtifactHandler
PATCH /qiita_db/artifacts/<artifact_id>/ op: operation, path: path, value: value Retrieves the artifact information ArtifactHandler
POST /qiita_db/artifact/ user_email: str, artifact_type: str, files: JSON of {'filepath_types': [filepaths]} command_artifact_name: str, job_id: str, optional, prep_id: int, optional, Injects artifacts to existing prep templates or jobs APIArtifactHandler
GET /qiita_db/users/   Retrieves the email and name of all the users UsersListDBHandler
GET /qiita_db/user/<email>/data/   Retrieves the user information UserInfoDBHandlerTests
GET /qiita_db/sample_information/<study_id>/data/   Retrieves the sample information contents SampleInfoDBHandler
GET /qiita_db/prep_template/<prep_id>/data/   Retrieves the preparation information contents PrepTemplateDataHandler
GET /qiita_db/prep_template/<prep_id>/   Retrieves the preparation information PrepTemplateDBHandler
GET /qiita_db/plugins/<plugin_name>/<version>/commands/<command_name>/activate/   Activates the command CommandActivateHandler
GET /qiita_db/plugins/<plugin_name>/<version>/commands/<command_name>/   Retrieve the command information CommandHandler
POST /qiita_db/plugins/<plugin_name>/<version>/commands/ name: <str>, description: <str>, required_parameters: <dict>, optional_parameters: <dict>, outputs: <list>, default_parameter_sets: <list>, analysis_only: <bool> Create new command for a plugin CommandListHandler
GET /qiita_db/plugins/<plugin_name>/<version>/   Retrieve the plugin information PluginHandler
GET /qiita_db/analysis/<analysis_id>/metadata/   Retrieves the analysis metadata APIAnalysisMetadataHandler
POST /qiita_db/archive/observations/ job_id: <str>, features: <list> Retrieves the archiving information APIArchiveObservations
PATCH /qiita_db/archive/observations/ path: <job_id>, req_value: <list> Retrieves the archiving information APIArchiveObservations

Qiita Internal REST API

This is the currently internal but planned to be external (general users) API.

Action URI Description
GET /api/v1/study/<int> Get study details (title, contacts, abstract, description and alias).
GET /api/v1/study/<int>/samples Get samples associated with a study and the available metadata headers for these samples.
PATCH /api/v1/study/<int>/samples Update sample metadata or add samples to the sample information.
GET /api/v1/study/<int>/samples?categories=foo,bar Get metadata categories foo and bar for all samples in the study.
GET /api/v1/study/<int>/status The status of a study (whether or not the study: is public, has sample information, sample information has warnings and a list of existing preparations.
GET /api/v1/person Get list of persons.
GET /api/v1/person?name=foo&affiliation=bar See if a person exists.
POST /api/v1/study Create a study (mirrors study creation on qiita UI with minimal requirements).
POST /api/v1/person?name=foo&affiliation=bar&email=address Create a study person (ie lab person or PI).
POST /api/v1/study/<int>/preparation Associate a prep with a study.
POST /api/v1/study/<int>/preparation/<int>/artifact Associate filepaths to a preparation, assuming this filepaths are present in the uploads folder.