---
title: "Start an ImportJob"
method: PUT
path: "/jobs/{id}/start"
tags: ["job"]
---

# Start an ImportJob

`PUT /jobs/{id}/start`

Starting an ImportJob forces it to immediatly import mock definitions

## Response `200`

Started ImportJob

- ImportJob — An ImportJob allow defining a repository artifact to poll for discovering Services and APIs mocks and tests
  - `id` string — Unique identifier of ImportJob
  - `name` string, required — Unique distinct name of this ImportJob
  - `repositoryUrl` string, required — URL of mocks and tests repository artifact
  - `repositoryDisableSSLValidation` boolean — Whether to disable SSL certificate verification when checking repository
  - `frequency` string — Reserved for future usage
  - `createdDate` string, date-time — Creation date for this ImportJob
  - `lastImportDate` string, date-time — Date last import was done
  - `lastImportError` string — Error message of last import (if any)
  - `active` boolean — Whether this ImportJob is active (ie. scheduled for execution)
  - `etag` string — Etag of repository URL during previous import. Is used for not re-importing if no recent changes
  - `serviceRefs` ServiceRef[] — References of Services discovered when checking repository
    - `serviceId` string, required — Unique reference of a Service
    - `name` string, required — The Service name
    - `version` string, required — The Service version
  - `metadata` Metadata — Commodity object for holding metadata on any entity. This object is inspired by Kubernetes metadata.
    - `createdOn` integer, required — Creation date of attached object
    - `lastUpdate` integer, required — Last update of attached object
    - `annotations` object — Annotations of attached object
    - `labels` object — Labels put on attached object
  - `secretRef` SecretRef — Lightweight reference for an existing Secret
    - `secretId` string, required — Unique identifier or referenced Secret
    - `name` string, required — Distinct name of the referenced Secret
  - `mainArtifact` boolean — Flag telling if considered as primary or secondary artifact. Default to `true`

---

[API](https://skmtc.dev/microcks/apis/microcks-api-v1-7.md) · [All operations](https://skmtc.dev/microcks/apis/microcks-api-v1-7/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/microcks/microcks-api-v1-7/revisions/cc062ec25192/schema)
