---
title: "Remotely configure a running File-Log agent"
method: POST
path: "/v1/agents/{agentId}/configuration"
tags: ["Agents"]
---

# Remotely configure a running File-Log agent

`POST /v1/agents/{agentId}/configuration`

-| This endpoint allows configuration of a running File-Log Agent with paths.  The File-Log Agent must be version 4.1.0 or greater, and configured to Receive Commands. Additionally, the Command Queue must be enabled for this Agent on TDP.
This will remove any paths not included in the JSON. To preserve existing paths, you must include them each time you POST.
If the target's command queue doesn't exist or is not accessible, the API will return a 400 error code and doesn't create the command.
For more details, see https://developers.tetrascience.com/docs/configuring-the-file-log-agent-in-the-cloud.

## Path parameters

- `agentId` string, required

## Request body

- object
  - `destination_id` string, uuid — **FLA v4.3.0+**: The Destination Id of the Agent
  - `services_enabled` string[], required — The services enabled for the Agent
  - `services_configuration` object, required
    - `fileWatcher` object, required
      - `use_path_configuration` boolean, required — Whether to use path level configuration for start date and interval. Must be set to true.
      - `paths` FLAFileWatcherPathConfigurationItem[]
        - `path` string, required — The path to watch.
        - `file_watch_mode` 'file' | 'folder', required — The file watch mode.
        - `source_type` string, required — The source type.
        - `interval` integer, required — The time in seconds the agent will monitor the files for changes before uploading. This also specifies the time between scans of the path.
        - `start_date` string, date, required — Files with a last modified date on or after the specified date will be scanned and uploaded.
        - `patterns` string[], required — Defines a list of [glob patterns](https://developers.tetrascience.com/docs/common-glob-pattern) to match files in the path.
        - `metadata` object — Custom metadata to associate with files in the path.
        - `tags` string — Comma-separated list of tags to associate with files in the path.
        - `labels` object[] — **FLA v4.3.0+**: Labels applied to files in the path
          - `name` string, required — The label name.
          - `value` string, required — The label value.
        - `archive` object — **FLA v4.3.0+**: Options for archival and deletion of files in the path after upload
          - `path` string, required — The location where files from this path will be archived
          - `wait_time` integer, required — Amount of time to wait before moving the source file to the archive path after uploading
          - `wait_time_unit` 'Minutes' | 'Hours' | 'Days', required — The unit for the wait_time
          - `archive_without_checksum` boolean — Determines if files uploaded by a previous agent version that have no checksum are archived or not.
          - `dry_run` boolean — Whether to perform a dry run
          - `delete` object — Options for deletion of files from the archive path
            - `wait_time` integer, required — Amount of time to wait before deleting the file from the archive path
            - `wait_time_unit` 'Minutes' | 'Hours' | 'Days', required — The unit for the wait_time
        - `fetch_os_created_user` boolean — Determines if the OS-created user metadata is retrieved and included as metadata on files in the path or not.
        - `symlink_behavior` 'Legacy' | 'Ignore' — **(For FLA v4.4.1 and higher only)** Specifies how the Agent handles symbolic links when file scanning.

## Response `200`

Successful response with the id to the command that executed the update

- object
  - `commandId` string

## Other responses

- `400` — Bad Request
- `404` — Agent not found

---

[API](https://skmtc.net/tetrascience/apis/tetra-data-lake.md) · [All operations](https://skmtc.net/tetrascience/apis/tetra-data-lake/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/tetrascience/tetra-data-lake/revisions/0205e2bace53/schema)
