API endpoint that allows jobs to be viewed or edited.

Pass the start_now url parameter to the POST method to enqueue the job immediately.

Use the delay field to create a test job with fake duration of work (in seconds).

Actions

/jobs/{id}/run/ (POST)

Run a job (add it to the queue).

/jobs/{id}/cancel/ (POST)

Cancel a job (terminate the background task)

GET /api/v2/jobs/1207/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, DELETE, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 1207,
    "details": "https://api.beluga.insectai.org/api/v2/jobs/1207/?format=api",
    "name": "Starred - Other models test",
    "delay": 0,
    "limit": null,
    "shuffle": true,
    "project": {
        "id": 18,
        "name": "Vermont Atlas of Life",
        "details": "https://api.beluga.insectai.org/api/v2/projects/18/?format=api",
        "user_permissions": []
    },
    "deployment": null,
    "source_image_collection": {
        "id": 11,
        "name": "Starred Images",
        "details": "https://api.beluga.insectai.org/api/v2/captures/collections/11/?format=api",
        "method": "starred",
        "user_permissions": []
    },
    "source_image_single": null,
    "pipeline": {
        "id": 2,
        "details": "https://api.beluga.insectai.org/api/v2/ml/pipelines/2/?format=api",
        "name": "UK & Denmark moths",
        "slug": "uk_denmark_moths_2023",
        "description": "",
        "version": 1,
        "version_name": "",
        "created_at": "2023-11-10T02:42:02.618036",
        "updated_at": "2026-04-01T17:09:36.587352",
        "user_permissions": []
    },
    "status": "SUCCESS",
    "created_at": "2025-01-27T11:15:46.867858",
    "updated_at": "2025-01-27T11:17:03.161764",
    "started_at": "2025-01-27T11:15:48.740780",
    "finished_at": "2025-01-27T11:17:03.161686",
    "duration": "74.420906",
    "progress": {
        "summary": {
            "status": "SUCCESS",
            "progress": 1.0
        },
        "stages": [
            {
                "status": "SUCCESS",
                "progress": 1.0,
                "key": "collect",
                "name": "Collect",
                "params": [
                    {
                        "name": "Total Images",
                        "key": "total_images",
                        "category": "default",
                        "value": 20
                    }
                ]
            },
            {
                "status": "SUCCESS",
                "progress": 1.0,
                "key": "process",
                "name": "Process",
                "params": [
                    {
                        "name": "Processed",
                        "key": "processed",
                        "category": "default",
                        "value": 20
                    },
                    {
                        "name": "Remaining",
                        "key": "remaining",
                        "category": "default",
                        "value": 0
                    },
                    {
                        "name": "Failed",
                        "key": "failed",
                        "category": "default",
                        "value": 0
                    }
                ]
            },
            {
                "status": "SUCCESS",
                "progress": 1.0,
                "key": "results",
                "name": "Results",
                "params": [
                    {
                        "name": "Captures",
                        "key": "captures",
                        "category": "default",
                        "value": 20
                    },
                    {
                        "name": "Detections",
                        "key": "detections",
                        "category": "default",
                        "value": 169
                    },
                    {
                        "name": "Classifications",
                        "key": "classifications",
                        "category": "default",
                        "value": 271
                    }
                ]
            }
        ],
        "errors": [],
        "logs": []
    },
    "logs": {
        "stdout": [
            "[2025-01-27 11:17:03] INFO Finished job #1207 \"Starred - Other models test\" (SUCCESS)",
            "[2025-01-27 11:17:03] INFO Changing status of job 1207 from STARTED to SUCCESS",
            "[2025-01-27 11:17:02] INFO Changing status of job 1207 from STARTED to SUCCESS",
            "[2025-01-27 11:17:02] INFO All tasks completed for job 1207",
            "[2025-01-27 11:16:59] INFO Waiting for batch 5 to finish saving results (sub-task 3746bf22-5382-4da8-8b5a-d6de1d3642f1)",
            "[2025-01-27 11:16:58] INFO Waiting for batch 5 to finish saving results (sub-task 3746bf22-5382-4da8-8b5a-d6de1d3642f1)",
            "[2025-01-27 11:16:58] INFO Checking the status of 1 remaining sub-tasks that are still saving results.",
            "[2025-01-27 11:16:58] INFO Processed 100% of images successfully.",
            "[2025-01-27 11:16:57] INFO Processed 100% of images successfully.",
            "[2025-01-27 11:16:57] INFO Saving results for batch 5 in sub-task 3746bf22-5382-4da8-8b5a-d6de1d3642f1",
            "[2025-01-27 11:16:56] INFO Processed image batch 5 in 13.04s",
            "[2025-01-27 11:16:56] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:55] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:54] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:52] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:51] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:50] INFO Pipeline results returned 4 images, 34 detections, 57 classifications",
            "[2025-01-27 11:16:45] INFO Sending 4 images to Pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:16:45] INFO Using processing service with latency 0.6249: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:44] INFO Using processing service with latency 0.6249: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:43] INFO Processing image batch 5 of 5",
            "[2025-01-27 11:16:43] INFO Saving results for batch 4 in sub-task 106da429-3884-436f-990c-15e6941dbce7",
            "[2025-01-27 11:16:42] INFO Saving results for batch 4 in sub-task 106da429-3884-436f-990c-15e6941dbce7",
            "[2025-01-27 11:16:42] INFO Processed image batch 4 in 16.33s",
            "[2025-01-27 11:16:42] INFO Pipeline results returned 4 images, 60 detections, 88 classifications",
            "[2025-01-27 11:16:41] INFO Pipeline results returned 4 images, 60 detections, 88 classifications",
            "[2025-01-27 11:16:36] INFO Sending 4 images to Pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:16:36] INFO Using processing service with latency 0.6136: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:35] INFO Using processing service with latency 0.6136: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:34] INFO Using processing service with latency 0.6136: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:33] INFO Using processing service with latency 0.6136: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:30] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:29] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:28] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:27] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:26] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:25] INFO Processing image batch 4 of 5",
            "[2025-01-27 11:16:25] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:24] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:23] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:22] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:21] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:20] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:19] INFO Saving results for batch 3 in sub-task 7360d81a-9e91-4cee-ad63-fb466bc96241",
            "[2025-01-27 11:16:18] INFO Processed image batch 3 in 4.14s",
            "[2025-01-27 11:16:18] ERROR b'Internal Server Error'",
            "[2025-01-27 11:16:16] INFO Sending 4 images to Pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:16:16] INFO Using processing service with latency 0.6097: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:14] INFO Processing image batch 3 of 5",
            "[2025-01-27 11:16:14] INFO Saving results for batch 2 in sub-task 70bf192a-47d4-4f8c-aeb5-367cbd4244f7",
            "[2025-01-27 11:16:13] INFO Processed image batch 2 in 11.05s",
            "[2025-01-27 11:16:12] INFO Processed image batch 2 in 11.05s",
            "[2025-01-27 11:16:11] INFO Processed image batch 2 in 11.05s",
            "[2025-01-27 11:16:10] INFO Pipeline results returned 4 images, 39 detections, 66 classifications",
            "[2025-01-27 11:16:09] INFO Pipeline results returned 4 images, 39 detections, 66 classifications",
            "[2025-01-27 11:16:08] INFO Pipeline results returned 4 images, 39 detections, 66 classifications",
            "[2025-01-27 11:16:02] INFO Sending 4 images to Pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:16:02] INFO Using processing service with latency 0.6108: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:01] INFO Using processing service with latency 0.6108: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:16:00] INFO Processing image batch 2 of 5",
            "[2025-01-27 11:16:00] INFO Saving results for batch 1 in sub-task 938d13e3-6238-472a-ab75-d3bedf505320",
            "[2025-01-27 11:16:00] INFO Processed image batch 1 in 7.86s",
            "[2025-01-27 11:16:00] INFO Pipeline results returned 4 images, 36 detections, 60 classifications",
            "[2025-01-27 11:15:54] INFO Sending 4 images to Pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:15:54] INFO Using processing service with latency 0.6867: #1 \"Rolnick Lab shared inference services\" at https://ml.dev.insectai.org/",
            "[2025-01-27 11:15:52] INFO Processing image batch 1 of 5",
            "[2025-01-27 11:15:52] INFO Shuffling images",
            "[2025-01-27 11:15:51] INFO Shuffling images",
            "[2025-01-27 11:15:50] INFO Found 20 out of 20 images to process",
            "[2025-01-27 11:15:49] INFO Found 20 out of 20 images to process",
            "[2025-01-27 11:15:49] INFO Filtering images that have already been processed by pipeline #2 \"UK & Denmark moths\" (uk_denmark_moths_2023) v1",
            "[2025-01-27 11:15:47] INFO Changing status of job 1207 from PENDING to STARTED",
            "[2025-01-27 11:15:47] INFO Running job #1207 \"Starred - Other models test\" (PENDING)"
        ],
        "stderr": [
            "b'Internal Server Error'"
        ]
    },
    "job_type": {
        "name": "ML pipeline",
        "key": "ml"
    },
    "data_export": null,
    "dispatch_mode": "internal",
    "result": null,
    "user_permissions": []
}