> For the complete documentation index, see [llms.txt](https://docs.datasaur.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.datasaur.ai/integrations/robosaur/commands.md).

# Commands

Currently Robosaur supports four commands: `create-projects`, `export-projects`, `apply-tags`, and `split-document`. All of these actions can be configured from the same configuration file. A configuration file must be properly filled before running the commands.

The example below shows a sample configuration structure. Several values can be customized based on your workflow. Refer to each command page for detailed configuration explanations. All values in the `<...>` format must be replaced with your own values.

{% code overflow="wrap" %}

```json
{
  "datasaur": { // mandatory attribute
    "host": "https://app.datasaur.ai", // should be adjusted if you use custom installation
    "clientId": "<DATASAUR_CLIENT_ID>",
    "clientSecret": "<DATASAUR_CLIENT_SECRET>"
  },
  "projectState": { // mandatory attribute
    "source": "local", // also support cloud object storage, see Storage Options page
    "path": "<path-to-JSON-state-file>"
  },
  "splitDocument": { // specifically for this, no need mandatory attributes above
    "path": "<path-to-a-file-that-will-be-split>",
    "header": true,
    "linesPerFile": 100,
    "filesPerFolder": 10,
    "resultFolder": "<path-to-all-split-files-result>"
  },
  "create": { // create-projects command
    "teamId": "<TEAM_ID>",
    "files": { // also support cloud object storage, see Storage Options page
      "source": "local",
      "path": "<path-to-data-source>"
    },
    "pcwAssignmentStrategy": "ALL", // or AUTO
    "pcwPayload": <paste-payload-from-PCW>
  },
  "applyTags": { // apply-tags command
    "teamId": "<TEAM_ID>",
    "source": "inline",
    "payload": [
      { "projectId": "<PROJECT_ID_1>", "tags": ["<TAG_1>", "<TAG_2>"] }
    ]
  },
  "export": { // export-projects command
    "source": "local", // also support cloud object storage, see Storage Options page
    "prefix": "<destination-path-for-exported-result>",
    "teamId": "<TEAM_ID>",
    "statusFilter": [],
    "format": "JSON_ADVANCED",
    "fileTransformerId": null
  }
}
```

{% endcode %}
