v1
Double column
API
CLI
JS Client

Jobs /

Edit job runtime environment

Deprecated

This endpoint is deprecated and will be removed in the future. Please avoid making requests to this endpoint.

Requests should instead use the relevant PATCH endpoint.

More details

Sets the runtime environment for the given job.

Required permission

Project > Secrets > Jobs > Update

Path parameters

    • projectId

      string required
      ID of the project
    • jobId

      string required
      ID of the job

Request body

  • {object}
    • runtimeEnvironment

      {object} required
      An object containing the all of the environment variables to set for the service. Keys may only contain letters, numbers, hyphens, forward slashes and dots.
      • runtimeFiles

        {object}
        Secret files as JSON object, encrypted at rest. File path must be absolute

      Response body

      • {object}
        Response object.
        • data

          {object} required
          Result data.
        API
        CLI
        JS Client

        POST /v1/projects/{projectId}/jobs/{jobId}/runtime-environment

        Example request

        Request body
        curl
        curl --header "Content-Type: application/json" \
          --header "Authorization: Bearer NORTHFLANK_API_TOKEN" \
          --request POST \
          --data '{"runtimeEnvironment":{"VARIABLE_1":"abcdef","VARIABLE_2":"12345"},"runtimeFiles":{"/dir/fileName":{"data":"VGhpcyBpcyBhbiBleGFtcGxlIHdpdGggYSB0ZW1wbGF0ZWQgJHtOT0RFX0VOVn0gdmFyaWFibGU=","encoding":"utf-8"}}}' \
          https://api.northflank.com/v1/projects/{projectId}/jobs/{jobId}/runtime-environment

        Example response

        200 OK

        The operation was performed successfully.

        JSON

        {
          "data": {}
        }

        © 2025 Northflank Ltd. All rights reserved.