Skip to content

BugSeq 0.1.0

users


GET /v1/users/me

Get Current User

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Response 200 OK

{
    "id": "string",
    "email": "string",
    "first_name": "string",
    "last_name": "string",
    "created": "2022-04-13T15:42:05.901Z",
    "affiliation": "string",
    "billing_account_id": "string",
    "pipeline_version": null,
    "pinned_region": null,
    "enabled_features": [
        "string"
    ]
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        },
        "email": {
            "type": "string",
            "title": "Email"
        },
        "first_name": {
            "type": "string",
            "title": "First Name"
        },
        "last_name": {
            "type": "string",
            "title": "Last Name"
        },
        "created": {
            "type": "string",
            "format": "date-time",
            "title": "Created"
        },
        "affiliation": {
            "type": "string",
            "title": "Affiliation"
        },
        "billing_account_id": {
            "type": "string",
            "title": "Billing Account Id"
        },
        "pipeline_version": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "Pipeline Version"
        },
        "pinned_region": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "Pinned Region"
        },
        "enabled_features": {
            "items": {
                "type": "string"
            },
            "type": "array",
            "title": "Enabled Features"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id",
        "email",
        "first_name",
        "last_name",
        "created",
        "affiliation",
        "billing_account_id",
        "enabled_features"
    ],
    "title": "UserResponse"
}

files


POST /v1/files/singlepart/init

Initialize Single Part Upload

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Request body

{
    "filename": "string",
    "s3_region": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the request body
{
    "properties": {
        "filename": {
            "type": "string",
            "title": "Filename"
        },
        "s3_region": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "S3 Region"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "filename"
    ],
    "title": "FileCreateS3Request"
}

Response 200 OK

{
    "id": "string",
    "presigned_s3_data": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        },
        "presigned_s3_data": {
            "title": "Presigned S3 Data"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id",
        "presigned_s3_data"
    ],
    "title": "FileInitUploadS3Response"
}

POST /v1/files/multipart/init

Initialize Multipart Upload

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Request body

{
    "filename": "string",
    "s3_region": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the request body
{
    "properties": {
        "filename": {
            "type": "string",
            "title": "Filename"
        },
        "s3_region": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "S3 Region"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "filename"
    ],
    "title": "FileCreateS3Request"
}

Response 200 OK

{
    "id": "string",
    "presigned_s3_data": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        },
        "presigned_s3_data": {
            "title": "Presigned S3 Data"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id",
        "presigned_s3_data"
    ],
    "title": "FileInitUploadS3Response"
}

POST /v1/files/multipart/chunk

Presign Multipart Chunk

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Request body

{
    "file_id": "string",
    "upload_id": "string",
    "part_number": 0
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the request body
{
    "properties": {
        "file_id": {
            "type": "string",
            "title": "File Id"
        },
        "upload_id": {
            "type": "string",
            "title": "Upload Id"
        },
        "part_number": {
            "type": "integer",
            "title": "Part Number"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "file_id",
        "upload_id",
        "part_number"
    ],
    "title": "FileMultipartChunkInitUploadRequest"
}

Response 200 OK

{
    "id": "string",
    "presigned_s3_data": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        },
        "presigned_s3_data": {
            "title": "Presigned S3 Data"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id",
        "presigned_s3_data"
    ],
    "title": "FileInitUploadS3Response"
}

POST /v1/files/multipart/complete

Complete Multipart Upload

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Request body

{
    "file_id": "string",
    "upload_id": "string",
    "parts": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the request body
{
    "properties": {
        "file_id": {
            "type": "string",
            "title": "File Id"
        },
        "upload_id": {
            "type": "string",
            "title": "Upload Id"
        },
        "parts": {
            "title": "Parts"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "file_id",
        "upload_id",
        "parts"
    ],
    "title": "FileMultipartUploadCompleteRequest"
}

Response 200 OK

Schema of the response body

jobs


POST /v1/jobs/

Submit Analysis

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token

Request body

{
    "user_provided_name": null,
    "aws_region": "string",
    "file_ids": [
        "string"
    ],
    "run_options": {
        "platform": "NANOPORE",
        "kit": null,
        "metagenomic_database": "BUGSEQ_DEFAULT",
        "sample_type": "ABSCESS",
        "molecule_type": "DNA",
        "include_in_lab_db": true,
        "filter_animal_reads": null
    },
    "lab_id": null,
    "testmode": true,
    "user_provided_metadata": null,
    "pipeline_version": null
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the request body
{
    "properties": {
        "user_provided_name": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "User Provided Name"
        },
        "aws_region": {
            "type": "string",
            "title": "Aws Region"
        },
        "file_ids": {
            "items": {
                "type": "string"
            },
            "type": "array",
            "title": "File Ids"
        },
        "run_options": {
            "$ref": "#/components/schemas/RunOptionsRequest"
        },
        "lab_id": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "Lab Id"
        },
        "testmode": {
            "type": "boolean",
            "title": "Testmode",
            "default": false
        },
        "user_provided_metadata": {
            "anyOf": [
                {
                    "items": {
                        "additionalProperties": {
                            "anyOf": [
                                {
                                    "type": "boolean"
                                },
                                {
                                    "type": "string"
                                }
                            ]
                        },
                        "type": "object"
                    },
                    "type": "array"
                },
                {
                    "type": "null"
                }
            ],
            "title": "User Provided Metadata"
        },
        "pipeline_version": {
            "anyOf": [
                {
                    "$ref": "#/components/schemas/PipelineVersion"
                },
                {
                    "type": "null"
                }
            ]
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "aws_region",
        "file_ids",
        "run_options"
    ],
    "title": "JobRunSubmitRequest"
}

Response 200 OK

{
    "id": "string"
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id"
    ],
    "title": "JobRunSubmitResponse"
}

GET /v1/jobs/

List Analyses

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token
ids query None No
lab_ids query None No
limit query integer 20 No
owner_ids query None No
skip query integer 0 No
user_provided_name query None No

Response 200 OK

{
    "job_runs": [
        {
            "id": "string",
            "user_provided_name": null,
            "owner_id": "string",
            "created": "2022-04-13T15:42:05.901Z",
            "end_time": null,
            "job_status": "created",
            "results_url": "string",
            "org_id": null,
            "pipeline_version": "latest"
        }
    ],
    "has_more": true
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "job_runs": {
            "items": {
                "$ref": "#/components/schemas/JobRunResponse"
            },
            "type": "array",
            "title": "Job Runs"
        },
        "has_more": {
            "type": "boolean",
            "title": "Has More"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "job_runs",
        "has_more"
    ],
    "title": "JobRunListResponse"
}

GET /v1/jobs/{job_id}/results

Get Analysis Results

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token
job_id path string No

Response 200 OK

{
    "id": "string",
    "user_provided_name": null,
    "owner_id": "string",
    "created": "2022-04-13T15:42:05.901Z",
    "end_time": null,
    "job_status": "created",
    "inputs": [
        {
            "filename": "string",
            "size": null
        }
    ],
    "outputs": null,
    "org_id": null,
    "pipeline_version": "latest"
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "id": {
            "type": "string",
            "title": "Id"
        },
        "user_provided_name": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "User Provided Name"
        },
        "owner_id": {
            "type": "string",
            "title": "Owner Id"
        },
        "created": {
            "type": "string",
            "format": "date-time",
            "title": "Created"
        },
        "end_time": {
            "anyOf": [
                {
                    "type": "string",
                    "format": "date-time"
                },
                {
                    "type": "null"
                }
            ],
            "title": "End Time"
        },
        "job_status": {
            "$ref": "#/components/schemas/JobStatus"
        },
        "inputs": {
            "items": {
                "$ref": "#/components/schemas/JobRunFileResponse"
            },
            "type": "array",
            "title": "Inputs"
        },
        "outputs": {
            "anyOf": [
                {
                    "items": {
                        "$ref": "#/components/schemas/JobRunFileResponse"
                    },
                    "type": "array"
                },
                {
                    "type": "null"
                }
            ],
            "title": "Outputs"
        },
        "org_id": {
            "anyOf": [
                {
                    "type": "string"
                },
                {
                    "type": "null"
                }
            ],
            "title": "Org Id"
        },
        "pipeline_version": {
            "$ref": "#/components/schemas/PipelineVersion"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "id",
        "owner_id",
        "created",
        "job_status",
        "inputs",
        "outputs",
        "org_id",
        "pipeline_version"
    ],
    "title": "JobRunResultsResponse"
}

GET /v1/jobs/{job_id}/results/download

Download Analysis Result

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token
filename query string No
job_id path string No

Response 200 OK

{
    "url": "string"
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "url": {
            "type": "string",
            "title": "Url"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "url"
    ],
    "title": "FileDownloadResponse"
}

billing


GET /v1/billing/{billing_account_id}/credits/sample

List Billing Account Sample Credits

Input parameters

Parameter In Type Default Nullable Description
HTTPBearer header string N/A No JWT Bearer token
billing_account_id path string No
include_expired query boolean True No
limit query integer 20 No
remaining_count_gt query None No
skip query integer 0 No
sort_by query string expiration No
sort_dir query string asc No

Response 200 OK

{
    "items": [
        {
            "id": "string",
            "sample_type": "metagenomic",
            "initial_count": 0,
            "remaining_count": 0,
            "expiration": "2022-04-13T15:42:05.901Z",
            "billing_account_id": "string",
            "created": "2022-04-13T15:42:05.901Z"
        }
    ],
    "has_more": true
}
⚠️ This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.

Schema of the response body
{
    "properties": {
        "items": {
            "items": {
                "$ref": "#/components/schemas/BillingAccountSampleCreditResponse"
            },
            "type": "array",
            "title": "Items"
        },
        "has_more": {
            "type": "boolean",
            "title": "Has More"
        }
    },
    "additionalProperties": false,
    "type": "object",
    "required": [
        "items",
        "has_more"
    ],
    "title": "ListBillingAccountSampleCreditResponse"
}

Schemas

BillingAccountSampleCreditResponse

Name Type
billing_account_id string
created string(date-time)
expiration string(date-time)
id string
initial_count integer
remaining_count integer
sample_type SampleType-Output

FileCreateS3Request

Name Type
filename string
s3_region

FileDownloadResponse

Name Type
url string

FileInitUploadS3Response

Name Type
id string
presigned_s3_data

FileMultipartChunkInitUploadRequest

Name Type
file_id string
part_number integer
upload_id string

FileMultipartUploadCompleteRequest

Name Type
file_id string
parts
upload_id string

HTTPValidationError

Name Type
detail Array<ValidationError>

JobRunFileResponse

Name Type
filename string
size

JobRunListResponse

Name Type
has_more boolean
job_runs Array<JobRunResponse>

JobRunResponse

Name Type
created string(date-time)
end_time
id string
job_status JobStatus
org_id
owner_id string
pipeline_version PipelineVersion
results_url string
user_provided_name

JobRunResultsResponse

Name Type
created string(date-time)
end_time
id string
inputs Array<JobRunFileResponse>
job_status JobStatus
org_id
outputs
owner_id string
pipeline_version PipelineVersion
user_provided_name

JobRunSubmitRequest

Name Type
aws_region string
file_ids Array<string>
lab_id
pipeline_version
run_options RunOptionsRequest
testmode boolean
user_provided_metadata
user_provided_name

JobRunSubmitResponse

Name Type
id string

JobStatus

Type: string

Kit

Type: string

ListBillingAccountSampleCreditResponse

Name Type
has_more boolean
items Array<BillingAccountSampleCreditResponse>

MetagenomicDatabase

Type: string

MoleculeType

Type: string

PipelineVersion

Type: string

Platform

Type: string

RunOptionsRequest

Name Type
filter_animal_reads
include_in_lab_db boolean
kit
metagenomic_database MetagenomicDatabase
molecule_type MoleculeType
platform Platform
sample_type SampleType-Input

SampleType-Input

Type: string

SampleType-Output

Type: string

UserResponse

Name Type
affiliation string
billing_account_id string
created string(date-time)
email string
enabled_features Array<string>
first_name string
id string
last_name string
pinned_region
pipeline_version

ValidationError

Name Type
loc Array<>
msg string
type string

Security schemes

Name Type Scheme Description
HTTPBearer http bearer