# Create Process

Creates custom processes with given arguments

About

Create Process endpoint creates a custom process with specified execution parameters. You can create a process by defining its path, arguments, execution type, and various configuration options. Processes are fundamental building blocks that can be used in actions and threat scenarios.

  • Process path and arguments define the executable and its parameters
  • Process type determines execution behavior (play or rewind)
  • Timeout and delay settings control execution timing
  • File associations and output handling provide additional functionality

Example for Basic Process Creation

Create a simple process with basic execution parameters.

curl --location 'https://api.picussecurity.com/v1/threat-library/processes' \
--header 'Authorization: Bearer access_token' \
--header 'Content-Type: application/json' \
--data '{
    "argument": "argument",
    "path": "path",
    "comment": "comment",
    "delay": 0,
    "timeout": 120000,
    "process_type": "play",
    "is_async": false,
    "success_cond_exist": false,
    "is_blocked": false,
    "output": "",
    "code": 0
}'
{
    "process": {
        "id": 1016265,
        "created_at": "2025-06-24T08:06:59.208273422Z",
        "path": "path",
        "argument": ""
    }
}

Required Fields

Process Type

  • Required: Yes
  • Type: String
  • Options: "play", "rewind"
  • Description: Defines the execution behavior of the process
    • play: Standard execution process
    • rewind: Cleanup/rollback process

Is Async

  • Required: Yes
  • Type: Boolean
  • Default: false
  • Description: Determines if the process should run asynchronously
    • true: Process runs in background without blocking
    • false: Process runs synchronously and blocks execution

Optional Fields

Argument

  • Required: No
  • Type: String
  • Description: Command line arguments to pass to the process

Path

  • Required: No
  • Type: String
  • Description: File path or executable path for the process

Comment

  • Required: No
  • Type: String
  • Description: Optional comment providing detailed information about the process's purpose, behavior, or execution methodology

Delay

  • Required: No
  • Type: Integer
  • Default: 0
  • Description: Delay in milliseconds before process execution starts

Timeout

  • Required: No
  • Type: Integer
  • Default: 120000 (2 minutes)
  • Description: Maximum execution time in milliseconds before process is terminated

Success Condition Exist

  • Required: No
  • Type: Boolean
  • Default: false
  • Description: Whether the process has custom success conditions defined

Is Blocked

  • Required: No
  • Type: Boolean
  • Default: false
  • Description: Whether the process execution should be blocked/prevented

Output

  • Required: No
  • Type: String
  • Description: Expected or captured output from the process

Code

  • Required: No
  • Type: Integer
  • Default: 0
  • Description: Expected exit code for successful process execution
Language
Credentials
Header
Click Try It! to start a request and see the response here!