Copy assets

post/v1/operations/copy
MCP ToolWrite
Page View

Subscription endpoints allow you to review, compare, and manage subscriptions and their related links to assets (i.e., filters, config modifiers, translation sets).

You must be a member of the environment and be assigned to an engineer role to manage subscriptions. Learn about roles.

Copy assets

Closed beta feature

This is a closed beta feature for a limited pilot group by invitation only. We’re not currently accepting additional participants, but we’ll let you know when it’s available to everyone.

Copy an asset to use existing logic as a base when creating a new asset. Each copy is an independent asset at version 1 that you can edit in the target environment.

You can copy assets within the same environment or across environments.

Assets are copied one at a time. The response lists which ones succeeded and which failed.

Request parameters and payload

cURL request example

bash
1
curl 'https://api.redoxengine.com/platform/v1/operations/copy' \
2
--request POST \
3
--header 'Authorization: Bearer $API_TOKEN' \
4
--header 'accept: application/json' \
5
--header 'content-type: application/json' \
6
--data '{
7
"fromEnvironment": {
8
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
9
},
10
"toEnvironment": {
11
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
12
},
13
"copyingAssets": [
14
{
15
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
16
"type": "configModifier",
17
"overrides": {
18
"name": "string"
19
}
20
}
21
]
22
}'

Request Body Schema

    Contains the required details to copy asset(s) from one environment to another.

  • fromEnvironment
    required, object

    Specifies where the original assets exist.

    • id
      required, string

      Contains the unique identifier of the Redox environment.

      Format: uuid
  • toEnvironment
    required, object

    Specifies where the new copies are created. The toEnvironment may or may not be the same as the fromEnvironment, but both must belong to the same organization.

    • id
      required, string

      Contains the unique identifier of the Redox environment.

      Format: uuid
  • copyingAssets
    required, Array of object

    Lists the assets to copy (max allowed is 50). If the same asset is listed twice, the request fails.

    • id
      required, string

      Contains the unique identifier of the asset.

      Format: uuid
    • type
      required, string
      Possible Values: configModifier, filter, translationSet
    • overrides
      object

      Contains any edits to the original asset's settings for the new copy. Any settings you don't override are taken from the original asset.

      • name
        string

        Names the copy. Defaults to the original asset's name followed by (copy). A translation set name must be unique within its environment; a duplicate name causes that translation set's copy to fail.

Response fields and example

Example payload generated from schema
1
{
2
"meta": {
3
"version": "1.0.0"
4
},
5
"payload": {
6
"copiedAssets": [
7
{
8
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
9
"name": "string",
10
"version": 1,
11
"environment": {
12
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
13
},
14
"type": "configModifier",
15
"copyingAsset": {
16
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
17
"name": "string",
18
"version": 2,
19
"environment": {
20
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
21
},
22
"type": "configModifier"
23
}
24
}
25
],
26
"failures": [
27
{
28
"copyingAsset": {
29
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
30
"type": "configModifier",
31
"overrides": {
32
"name": "string"
33
}
34
},
35
"error": {
36
"id": "string",
37
"code": "asset.not.found",
38
"title": "Not Found",
39
"detail": "string",
40
"meta": {
41
"isTransient": true
42
}
43
}
44
}
45
]
46
}
47
}
  • meta
    object
    • version
      string

      Lists the major and minor version number for the format of the returned payload. The payload format or shape may change between minor versions, like including additional or extended fields in later versions. We include the version data in each response so that you have the option to handle the signaled differences.

  • payload
    object
    • copiedAssets
      Array of object

      Lists the new assets and their corresponding IDs in the toEnvironment. For copied translation sets, any value sets are also automatically copied and listed with the type valueSet.

      • id
        string

        Contains the unique identifier of the asset.

        Format: uuid
      • name
        string

        Contains the human-readable name of the asset.

      • version
        number

        Always set to 1. A copy is a new asset, regardless of the original asset's version number.

      • environment
        object

        Describes the Redox environment that the asset belongs to.

        • id
          string

          Contains the unique identifier of the Redox environment.

          Format: uuid
      • type
        string

        Identifies the type of a copied asset. valueSet appears only for the value sets copied along with a translation set.

        Possible Values: configModifier, filter, translationSet, valueSet
      • copyingAsset
        object

        Describes the original asset being copied. The response is the only record of this relationship, since a copied asset is independent of the original.

        • id
          string

          Contains the unique identifier of the asset.

          Format: uuid
        • name
          string

          Contains the human-readable name of the asset.

        • version
          number

          Contains the numeric version of the asset. Version numbers start at 1 and increment in whole numbers whenever the asset is updated.

        • environment
          object

          Describes the Redox environment that the asset belongs to.

          • id
            string

            Contains the unique identifier of the Redox environment.

            Format: uuid
        • type
          string

          Identifies the type of a copied asset. valueSet appears only for the value sets copied along with a translation set.

          Possible Values: configModifier, filter, translationSet, valueSet
    • failures
      Array of object

      Lists any assets that weren't copied, along with the error that prevented it. See error.meta.isTransient to learn whether you can safely retry copying an asset. This array is empty when every asset copied successfully.

      • copyingAsset
        object

        Identifies one asset in the fromEnvironment to copy.

        • id
          required, string

          Contains the unique identifier of the asset.

          Format: uuid
        • type
          required, string
          Possible Values: configModifier, filter, translationSet
        • overrides
          object

          Contains any edits to the original asset's settings for the new copy. Any settings you don't override are taken from the original asset.

          • name
            string

            Names the copy. Defaults to the original asset's name followed by (copy). A translation set name must be unique within its environment; a duplicate name causes that translation set's copy to fail.

      • error
        object

        Explains why one item in a bulk request failed. The overall request still returns 200. A request that's rejected before any work starts (e.g., due to a malformed body) returns 400 instead.

        • id
          required, string

          Contains a unique identifier for this error instance.

        • code
          required, string

          Identifies the error type, which can be used to find relevant troubleshooting information.

        • title
          required, string

          Displays the high-level error message.

        • detail
          required, string

          Contains the specific error details for this item.

        • meta
          object

          Contains additional details about the failure. Some errors add other properties, such as the ID of an asset that was partially created.

          • isTransient
            boolean

            Indicates whether retrying this item as-is might succeed. true means the failure was temporary (e.g., a timeout), so you can retry the item. false means the item will continue to fail until you correct the issue (e.g., the asset doesn't exist or its name is a duplicate). When absent, the failure wasn't classified; review detail before retrying.

FHIR® is a registered trademark of Health Level Seven International (HL7) and is used with the permission of HL7. Use of this trademark does not constitute an endorsement of products/services by HL7®.