---
updatedAt: 2026-04-21T04:46:34.000Z
agentTools:
  projectIndex: https://developer.alloy.com/public/llms.txt
---

# Update Published Attribute

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Alloy API",
    "version": "1.0.0",
    "description": "hey hey hey, it's the Alloy API!"
  },
  "servers": [
    {
      "url": "https://sandbox.alloy.co/v1",
      "description": "Sandbox endpoint"
    }
  ],
  "security": [
    {
      "oauth2": []
    },
    {
      "basic": []
    }
  ],
  "tags": [
    {
      "name": "Published Attributes",
      "description": "Published attributes provide a mechanism to persist custom data on an entity then decision on that data throughout the entity's lifecycle."
    }
  ],
  "paths": {
    "/published-attributes/{published-attribute-token}": {
      "parameters": [
        {
          "in": "path",
          "name": "published-attribute-token",
          "schema": {
            "type": "string"
          },
          "required": true,
          "description": "Published attribute token associated with published attribute. Token is available via the Published Attribute List on the Settings page of the dashboard if needed."
        }
      ],
      "patch": {
        "summary": "Update Published Attribute",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdatePublishedAttributeDefinition"
              }
            }
          }
        },
        "tags": [
          "Published Attributes"
        ],
        "responses": {
          "200": {
            "x-summary": "OK",
            "description": "Update the published attribute specified by the token in the path and the fields provided in the payload.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublishedAttributeTokenPATCH200Response"
                }
              }
            }
          },
          "404": {
            "x-summary": "Resource not found.",
            "description": "Unable to find the published attribute token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublishedAttribute404Response"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "basic": {
        "type": "http",
        "description": "HTTP basic authorization using a workflow token and secret",
        "scheme": "basic"
      },
      "oauth2": {
        "type": "oauth2",
        "description": "Oauth2 using a workflow token and secret to generate a bearer token",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "/oauth/bearer",
            "scopes": {}
          }
        }
      }
    },
    "schemas": {
      "PublishedAttributeDefinition": {
        "type": "object",
        "properties": {
          "published_attribute_token": {
            "type": "string",
            "readOnly": true,
            "description": "An Alloy system generated unique ID for the published attribute."
          },
          "published_attribute_name": {
            "description": "The name of the published attribute.\n- If the published attribute is an input attribute in a workflow, this name will serve as the selector in the Evaluation payload.\n- When creating transactions via the Events API (`transaction` events), you can include published attribute values directly in the event data payload using this name as the field name.\n",
            "type": "string"
          },
          "data_type": {
            "description": "The data type of the published attribute.",
            "type": "string",
            "enum": [
              "integer",
              "decimal",
              "string",
              "boolean",
              "date",
              "timestamp"
            ]
          },
          "default_value": {
            "description": "A default value is assigned to the published attribute for each object of the `object_type`. If the published attribute is being used as an input attribute, then this value will be used if there is no value provided in the evaluation payload.",
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              },
              {
                "type": "boolean"
              }
            ]
          },
          "default_value_note": {
            "description": "A description of the default value.",
            "type": "string",
            "nullable": true
          },
          "contains_pii": {
            "description": "This is set to true when the published attribute contains PII. If it's true this field will be stored encrypted. Unable to be changed once set.",
            "type": "boolean"
          },
          "object_type": {
            "description": "The object type to which this published attribute applies.\n- `entity`: Published attribute values are associated with entities and require either `entity_token` or `external_entity_id`\n- `transaction`: Published attribute values are associated with transactions and require a `transaction_token`\n",
            "type": "string",
            "enum": [
              "entity",
              "transaction"
            ]
          },
          "value_expires_in": {
            "description": "The number of seconds that this published attribute's values will persist for.",
            "type": "integer",
            "nullable": true
          },
          "jq_filter": {
            "description": "A way to transform JSON using the jq cli tool.",
            "type": "string",
            "nullable": true
          },
          "description": {
            "description": "A description of the published attribute.",
            "type": "string",
            "nullable": true
          }
        }
      },
      "PublishedAttributeDefinitionWithArchived": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/PublishedAttributeDefinition"
          }
        ],
        "properties": {
          "archived": {
            "type": "boolean",
            "description": "indicates whether the published attribute has been archived"
          }
        }
      },
      "PublishedAttribute404Response": {
        "type": "object",
        "properties": {
          "status_code": {
            "type": "number"
          },
          "timestamp": {
            "type": "string"
          },
          "evaluation_token": {
            "type": "string",
            "nullable": true
          },
          "entity_token": {
            "type": "string",
            "nullable": true
          },
          "application_token": {
            "type": "string",
            "nullable": true
          },
          "application_version_id": {
            "type": "string",
            "nullable": true
          },
          "error": {
            "type": "object",
            "properties": {
              "minor_code": {
                "type": "number",
                "description": "The minor code associated with the error."
              },
              "type": {
                "type": "string",
                "description": "The type of error."
              },
              "message": {
                "type": "string",
                "description": "A message indicating what the error is."
              },
              "details": {
                "type": "object",
                "description": "The details of the error."
              }
            }
          }
        },
        "example": {
          "status_code": 404,
          "error": {
            "minor_code": 4041,
            "type": "Not Found",
            "message": "Unable to find the requested resource",
            "details": {
              "published_attribute_token": "PA-1234335"
            },
            "error_token": "6c5d6876-653f-4052-a1d8-061b2aa16ae9"
          },
          "timestamp\"": 1693102054905,
          "evaluation_token\"": null,
          "entity_token\"": "P-tT3pDKz0586mAsPSX9ZW",
          "application_token\"": "awergawerfg5s32323223",
          "application_version_id\"": null
        }
      },
      "UpdatePublishedAttributeDefinition": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/PublishedAttributeDefinitionWithArchived"
          }
        ],
        "properties": {
          "data_type": {
            "readOnly": true
          },
          "object_type": {
            "readOnly": true
          },
          "contains_pii": {
            "readOnly": true
          },
          "published_attribute_name": {
            "description": "The name of the published attribute. If the published attribute is an input attribute in a workflow, this name will serve as the selector in the Evaluation payload. Care should be taken when the name is changed. See the published attribute guide documentation for details",
            "type": "string"
          }
        }
      },
      "PublishedAttributeTokenPATCH200Response": {
        "type": "object",
        "properties": {
          "published_attribute_token": {
            "type": "string",
            "description": "The published attribute token that was updated."
          },
          "message": {
            "type": "string",
            "description": "The message signifying that published attribute was successfully updated."
          }
        },
        "example": {
          "published_attribute_token": "PA-54eKJIaGGzXdJcyBgrqK",
          "message": "published attribute has been updated"
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": false
  }
}
```