> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://nemo-platform.docs.buildwithfern.com/nemo/platform/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://nemo-platform.docs.buildwithfern.com/nemo/platform/_mcp/server.

# Pause Job

POST https://host.com/apis/jobs/v2/workspaces/{workspace}/jobs/{name}/pause

Pause a platform job.

Reference: https://nemo-platform.docs.buildwithfern.com/nemo/platform/nemo/platform/documentation/reference/api-reference/jobs/pause-job-apis-jobs-v-2-workspaces-workspace-jobs-name-pause-post

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: Nemo Platform API
  version: 1.0.0
paths:
  /apis/jobs/v2/workspaces/{workspace}/jobs/{name}/pause:
    post:
      operationId: pause-job-apis-jobs-v-2-workspaces-workspace-jobs-name-pause-post
      summary: Pause Job
      description: Pause a platform job.
      tags:
        - subpackage_jobs
      parameters:
        - name: name
          in: path
          required: true
          schema:
            type: string
        - name: workspace
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PlatformJobResponse'
        '404':
          description: Job not Found
          content:
            application/json:
              schema:
                description: Any type
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
servers:
  - url: https://host.com
    description: Default
components:
  schemas:
    PlatformJobSecretEnvironmentVariableRef:
      type: object
      properties:
        name:
          type: string
          description: The name of the secret to reference
      required:
        - name
      description: >-
        Reference to a secret to populate an environment variable for a job
        step.
      title: PlatformJobSecretEnvironmentVariableRef
    PlatformJobEnvironmentVariable:
      type: object
      properties:
        name:
          type: string
          description: The environment variable name
        value:
          type: string
          description: The environment variable value
        from_secret:
          $ref: '#/components/schemas/PlatformJobSecretEnvironmentVariableRef'
          description: >-
            Reference to a secret environment variable to populate the
            environment variable
      required:
        - name
      description: Environment variable for a job step
      title: PlatformJobEnvironmentVariable
    ContainerSpec:
      type: object
      properties:
        image:
          type: string
        entrypoint:
          type: array
          items:
            type: string
        command:
          type: array
          items:
            type: string
      required:
        - image
      description: |-
        Specification for a container configuration.

        Defines the container image and related configuration for job execution.
      title: ContainerSpec
    ComputeResourceSpec:
      type: object
      properties:
        cpu:
          type: string
          description: CPU specification (e.g., '250m', '1', '2.5').
        memory:
          type: string
          description: Memory specification (e.g., '128Mi', '1Gi', '512M').
      description: Resource specification.
      title: ComputeResourceSpec
    ComputeResources:
      type: object
      properties:
        requests:
          $ref: '#/components/schemas/ComputeResourceSpec'
          description: Minimum resources requested for the container.
        limits:
          $ref: '#/components/schemas/ComputeResourceSpec'
          description: Maximum resources the container can use.
        num_nodes:
          type: integer
          default: 1
          description: Number of nodes to use.
        num_gpus:
          type: integer
          description: Step requesting number of GPUs.
        shm_size:
          type: string
          description: >-
            Shared memory (/dev/shm) size as a Kubernetes quantity (e.g. '1Gi',
            '4Gi'). Used for GPU and distributed-GPU job executors. When unset,
            defaults to 1Gi per allocated GPU.
      description: Resource requirements matching k8s ResourceRequirements format.
      title: ComputeResources
    PlatformJobStepSpecOutputExecutor:
      oneOf:
        - type: object
          properties:
            provider:
              type: string
              enum:
                - cpu
              description: 'Discriminator value: cpu'
            profile:
              type: string
              default: default
            container:
              $ref: '#/components/schemas/ContainerSpec'
            resources:
              $ref: '#/components/schemas/ComputeResources'
              description: Resource requests and limits for CPU execution.
          required:
            - provider
            - container
          description: |-
            CPU-based execution provider.

            Provides configuration for running jobs on CPU resources with
            resource requests and limits.
        - type: object
          properties:
            provider:
              type: string
              enum:
                - gpu
              description: 'Discriminator value: gpu'
            profile:
              type: string
              default: default
            container:
              $ref: '#/components/schemas/ContainerSpec'
            resources:
              $ref: '#/components/schemas/ComputeResources'
              description: Resource requests and limits for GPU execution.
          required:
            - provider
            - container
          description: |-
            GPU-based execution provider.

            Provides configuration for running jobs on GPU resources with
            resource requests and limits.
        - type: object
          properties:
            provider:
              type: string
              enum:
                - gpu_distributed
              description: 'Discriminator value: gpu_distributed'
            profile:
              type: string
              default: default
            container:
              $ref: '#/components/schemas/ContainerSpec'
            resources:
              $ref: '#/components/schemas/ComputeResources'
              description: Resource requests and limits for distributed GPU execution.
          required:
            - provider
            - container
          description: |-
            GPU-based execution provider.

            Provides configuration for running jobs on GPU resources with
            resource requests and limits.
        - type: object
          properties:
            provider:
              type: string
              enum:
                - subprocess
              default: subprocess
            profile:
              type: string
              default: default
            command:
              type: array
              items:
                type: string
          required:
            - provider
            - command
          description: Host subprocess execution provider.
      discriminator:
        propertyName: provider
      description: The executor for the step
      title: PlatformJobStepSpecOutputExecutor
    StepLifecycle:
      type: object
      properties:
        staleness_timeout_seconds:
          type: integer
          default: 0
          description: >-
            If every active task in the step goes this many seconds without an
            update, the step is terminated. A value of 0 disables staleness
            detection.
      description: |-
        Controller-level lifecycle configuration for a job step.

        These settings control how the jobs controller manages the step,
        as opposed to ``config`` which is the task payload forwarded to
        the container.
      title: StepLifecycle
    PlatformJobStepSpecOutput:
      type: object
      properties:
        name:
          type: string
          description: >-
            The name of the step. Must be unique for all steps in a job. Name
            must start with a lowercase letter, be 2-63 characters, and contain
            only lowercase letters, digits, and hyphens (no consecutive hyphens,
            cannot end with a hyphen).
        environment:
          type: array
          items:
            $ref: '#/components/schemas/PlatformJobEnvironmentVariable'
          description: Environment variables for the step
        executor:
          $ref: '#/components/schemas/PlatformJobStepSpecOutputExecutor'
          description: The executor for the step
        config:
          type: object
          additionalProperties:
            description: Any type
          description: Configuration for the step
        lifecycle:
          $ref: '#/components/schemas/StepLifecycle'
          description: Lifecycle configuration settings for the step
      required:
        - name
        - executor
      description: Specification for a single step in a platform job.
      title: PlatformJobStepSpecOutput
    PlatformJobSpecOutput:
      type: object
      properties:
        steps:
          type: array
          items:
            $ref: '#/components/schemas/PlatformJobStepSpecOutput'
          description: List of steps to be executed in the job
      required:
        - steps
      description: Specification for a platform job, containing steps and secrets.
      title: PlatformJobSpecOutput
    PlatformJobStatus:
      type: string
      enum:
        - created
        - pending
        - active
        - cancelled
        - cancelling
        - error
        - completed
        - paused
        - pausing
        - resuming
      description: >-
        Enumeration of possible job statuses.


        This enum represents the various states a job can be in during its
        lifecycle,

        from creation to a terminal state.
      title: PlatformJobStatus
    PlatformJobResponse:
      type: object
      properties:
        id:
          type: string
        attempt_id:
          type: string
        name:
          type: string
        workspace:
          type: string
          description: Workspace identifier
        project:
          type: string
          description: Project URN
        description:
          type: string
        source:
          type: string
        spec:
          type: object
          additionalProperties:
            description: Any type
          description: Job Spec
        platform_spec:
          $ref: '#/components/schemas/PlatformJobSpecOutput'
        fileset:
          type: string
          description: Fileset ID for storing job artifacts
        status:
          $ref: '#/components/schemas/PlatformJobStatus'
        status_details:
          type: object
          additionalProperties:
            description: Any type
          description: Details about the job status
        error_details:
          type: object
          additionalProperties:
            description: Any type
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        ownership:
          type: object
          additionalProperties:
            description: Any type
        custom_fields:
          type: object
          additionalProperties:
            description: Any type
          description: Custom Fields
      required:
        - id
        - attempt_id
        - name
        - workspace
        - source
        - platform_spec
        - fileset
        - status
      description: Response model for a platform job.
      title: PlatformJobResponse
    ValidationErrorLocItems:
      oneOf:
        - type: string
        - type: integer
      title: ValidationErrorLocItems
    ValidationError:
      type: object
      properties:
        loc:
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorLocItems'
        msg:
          type: string
        type:
          type: string
        input:
          description: Any type
        ctx:
          type: object
          additionalProperties:
            description: Any type
      required:
        - loc
        - msg
        - type
      title: ValidationError
    HTTPValidationError:
      type: object
      properties:
        detail:
          type: array
          items:
            $ref: '#/components/schemas/ValidationError'
      title: HTTPValidationError

```

## Examples



**Request**

```json
{}
```

**Response**

```json
{
  "id": "job-12345",
  "attempt_id": "attempt-67890",
  "name": "data-cleaning-job",
  "workspace": "research-team-alpha",
  "source": "git@github.com:nemo/data-pipeline.git",
  "platform_spec": {
    "steps": [
      {
        "name": "preprocess",
        "executor": {
          "provider": "cpu",
          "container": {
            "image": "nemo/data-preprocess:1.4.2",
            "entrypoint": [
              "/bin/sh",
              "-c"
            ],
            "command": [
              "python preprocess.py --input /data/raw --output /data/clean"
            ]
          },
          "profile": "default",
          "resources": {
            "requests": {
              "cpu": "500m",
              "memory": "1Gi"
            },
            "limits": {
              "cpu": "1",
              "memory": "2Gi"
            },
            "num_nodes": 1,
            "num_gpus": 0,
            "shm_size": "1Gi"
          }
        },
        "environment": [
          {
            "name": "ENVIRONMENT",
            "value": "production"
          },
          {
            "name": "API_KEY",
            "from_secret": {
              "name": "nemo_api_key"
            }
          }
        ],
        "config": {},
        "lifecycle": {
          "staleness_timeout_seconds": 300
        }
      }
    ]
  },
  "fileset": "fileset-98765",
  "status": "paused",
  "project": "urn:nemo:project:data-pipeline-v2",
  "description": "Job to clean and preprocess raw data for analysis",
  "spec": {},
  "status_details": {},
  "error_details": {},
  "created_at": "2024-01-15T09:30:00Z",
  "updated_at": "2024-01-15T10:00:00Z",
  "ownership": {},
  "custom_fields": {}
}
```

**SDK Code**

```python
import requests

url = "https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause"

payload = {}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause';
const options = {method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{}'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause', [
  'body' => '{}',
  'headers' => [
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause");
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["Content-Type": "application/json"]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://host.com/apis/jobs/v2/workspaces/workspace/jobs/name/pause")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```