---
id: parameter-write
title: "Update a parameter"
description: "Updates a field of a parameter. **Replacing a field **doesn't** affect the underlying parameter values.**"
sidebar_label: "Update a parameter"
hide_title: true
hide_table_of_contents: true
api: eJzdWG2P27gR/isDfmliyF7vSw6F2hzg26a4PRTJYteLHm53YdPi2OKdRCokZccx9N+LISVbXil7e23uWhRIHEUiZx7OyzPD2TGBNjGycFIrFrO7QnCHFjgsJWYC9BI4FNzwHB2aEQwGN1hkPJFqtV8zGAiNVv3JDQbAl0tMHLgUoVQCTballXsBsOZZiXY0GLCI7d9aFt/vmOI5sphJwSImCUvBXcqiJwCnKcLV3wgX6TggYxEz+LGUBgWLnSkxYjZJMecs3jG3LUi0dUaqFauqx4jpAg0nmVfCq6rlxBsjHbKIOb4iWOy6+cIegwa07jsttiQ20cqhcvTIiyKTiRd48rMlpLuufr34GRNHJzek3km09HXNjeSLDLtI+w5PZmqOj2otjVY5KgeNFNikqPzXOQmbQ61sC9KCRQdOw7y1cU6mw088LwKCAxp2/eHDP2a3Vz+9Y1VVRcxJ51/vjTXzxprVVqFFVcQsJqWRbut9ukBu0ExKl7L4/rHyJrSFVjac/Gw8pn+6h9x7Bzbcgi2TBK1dlhlh/betfoiP+xBlPuIipowih9PqiKFKtAi2t5gYDBu5mGmVbVnEQgDTAxortZpJQZFx7FEpWvqlcrhC03HmBOzWOsyHGykoW+TH0of2UptubO8ddHp2flHV0H9zvPSLZNdaZ3ArPyOrgjVeJPj9zftGbssPsEllkh5rgwVmWq0sOH2sWJsVV/Kz3/j2NOZJokvl3p7FBNoWPMG353FL+NsLQhig7VpyWuHcC5V29Nrg6SlRlTmFx7FAWMoMycvdDPACqlbYHOEqMk7e/9SPqtnTQRZY8jl8bcGw4Ba/uejHt8dVRV+ZZ0ZwU+dTYJyabaR9yi6Vl+6k8i6ceVZ/EYJlmWXe9EB7ntFHa4KiOmUP4hdaZ8hVR/6VEhRTaEmYSzGknLc7ieQQJI1gTrVkDnIJ0rW/RDBf8sziHDRt30jrHVY7yB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Rk+srsFLg/1lq2LYh6mB4Q6nxZnxGP+fHjn/z38sKOqyvLGHRLJjsD8uPq1o91KHzjtaETKE3MkG4U3zNpW8XOgnTu/13TZ2JglLhpwITh6I+kk6S0hgUI7jOkFsEZ7bAV1wqyLgfUlRN2uToUh2GlS5J/fyUbtLs0P+d7KSo/OCKThSmqqXJqMg6V9j45IQXckQNVJFxR2k7SnTOaCzXTO1uKVNCgLdnd3tTkCBWj1Y9M/pFLKof/t407z/8c8oINGXgzWFq+q5vzvjFmSPNgZfaLwj3SRaz09F4NGaHMnx9GCJXESu0dTn3OV+Pk8NAuz3EfurH1hz3Dx1/1xalKc6Jn+fQAby7drVr71kbdBwmjam2jj7tdjT3uTNZVdHrjyVSD3P/2J7z3O+YkJaeBYv9nf+Zs79q5iuv4Zkhey/q5hav9hNSFjMWsV9wGyb6Fc0aUuQCjUcVPlwG3cNpGL02GzsMXkXNDroJFe7ZtY+tTLmeTC+/p+CsB/a5p0lm+Iaon28CSu2N4WPev9uxjKtV6TmABaEUi/w4E55Evj9Wrx12u7Biqn9BVVV7szj6P1mmqv4FhnXXYw==
sidebar_class_name: "patch api-method"
info_path: docs/api/parameters
custom_edit_url: null
---

import MethodEndpoint from "@theme/ApiExplorer/MethodEndpoint";
import ParamsDetails from "@theme/ParamsDetails";
import RequestSchema from "@theme/RequestSchema";
import StatusCodes from "@theme/StatusCodes";
import OperationTabs from "@theme/OperationTabs";
import TabItem from "@theme/TabItem";
import Heading from "@theme/Heading";

<Heading
  as={"h1"}
  className={"openapi__heading"}
  children={"Update a parameter"}
>
</Heading>

<MethodEndpoint
  method={"patch"}
  path={"/parameter/{id}"}
  context={"endpoint"}
>
  
</MethodEndpoint>



Updates a field of a parameter. **Replacing a field **doesn't** affect the underlying parameter values.**

<Heading
  id={"request"}
  as={"h2"}
  className={"openapi-tabs__heading"}
  children={"Request"}
>
</Heading>

<ParamsDetails
  parameters={[{"name":"id","in":"path","description":"The ID of the parameter.","required":true,"schema":{"type":"string"}}]}
>
  
</ParamsDetails>

<RequestSchema
  title={"Body"}
  body={{"content":{"application/json":{"schema":{"type":"object","properties":{"variable":{"type":"string","description":"The name of the environment variable when the `type` property is set to `environment`.","example":{"variable":"POOL_SIZE"}}},"title":"parameter_write_request"}}}}}
>
  
</RequestSchema>

<StatusCodes
  id={undefined}
  label={undefined}
  responses={{"200":{"description":"The operation was successful.","content":{"application/json":{"schema":{"type":"object","required":["id","name","nrn","type","encoding","secret","read_only","values","version_id"],"properties":{"id":{"type":"integer","description":"A system-wide unique ID for the parameter.","example":1234},"name":{"type":"string","description":"The name of the parameter.","example":"Pool Size"},"nrn":{"type":"string","description":"The NRN of the application which the parameter belongs to.","example":"organization=1:account=2:namespace=3:application=4"},"type":{"example":"environment","description":"The type of the parameter.","type":"string","enum":["environment"," file"],"title":"parameter_type"},"encoding":{"example":"plaintext","description":"The encoding of the parameter value.","type":"string","enum":["plaintext"," base64"],"title":"parameter_encoding"},"variable":{"type":"string","description":"The name of the environment variable. Required when `type` is `environment`."},"destination_path":{"type":"string","description":"The full file path. Required when `type` is `file`."},"secret":{"type":"boolean","description":"Indicates whether the value is a secret. `true` if it is a secret, `false` otherwise.","enum":[true,false]},"read_only":{"type":"boolean","description":"Indicates whether the value is read-only. `true` if it is read-only, `false` otherwise.","enum":[true,false]},"version_id":{"type":"integer","description":"A system-wide unique ID for the parameter version.","example":12341234},"values":{"type":"array","items":{"description":"The parameter values for this application or scopes.","type":"object","required":["id","nrn","created_at"],"properties":{"id":{"type":"integer","description":"A system-wide unique ID for the value.","example":1234},"nrn":{"type":"string","description":"The NRN of the application which the parameter belongs to.","example":"organization=1:account=2:namespace=3:application=4"},"created_at":{"type":"string","description":"The ISO-8601 UTC timestamp of when the parameter value was created.","format":"date-time","example":"2021-01-02T00:00:00Z"},"value":{"type":"string","nullable":true,"description":"The value of the parameter.<br><br>\n> **Note:** If `show_secret_values` is set to `true`, the value is **only visible to users with the required permission**. See [Accessing secret values](/docs/parameters/secret-visibility) for more details.\n","example":"200"},"location":{"type":"string","description":"The file path. Applicable only for files; null otherwise. Also null for secrets.","example":null},"external":{"type":"object","nullable":true,"description":"Object containing the external ID and engine of the value. \n>  **Note:** Applicable only for parameters stored in your own (external) infrastructure.\n","required":["id","engine"],"properties":{"id":{"description":"The external ID of the value.","type":"string","example":"external_id_123"},"engine":{"description":"The engine of the value. \n\n> **Note:** At the moment, only `hcp_vault` is supported.\n","type":"string","example":"hcp_vault"}}},"dimensions":{"type":"object","description":"The dimensions of the value.","example":{"environment":"development","country":"US"}}},"title":"parameter_value"}}},"title":"parameterResponse"}}}},"4XX":{"description":"Client error responses due to invalid input or missing parameters.","content":{"application/json":{"schema":{"type":"object","required":["statusCode","error","message"],"properties":{"statusCode":{"type":"integer","description":"HTTP status code representing the specific client error (e.g., 400, 401, 403, 404).","example":400},"code":{"type":"string","description":"A machine-readable error code that categorizes the server failure.","example":"bad_request"},"error":{"type":"string","description":"A brief, human-readable description of the error type (e.g., \"Bad Request\", \"Unauthorized\").","example":"Bad Request"},"message":{"type":"string","description":"Additional details about the error.","example":"The request was malformed or contained invalid parameters."}}}}}},"5XX":{"description":"Server error responses indicating an issue on the API side.","content":{"application/json":{"schema":{"type":"object","required":["statusCode","error","message"],"properties":{"statusCode":{"type":"integer","description":"HTTP status code representing the specific server error (e.g., 500, 502, 503).","example":500},"code":{"type":"string","description":"A machine-readable error code that categorizes the server failure.","example":"internal_server_error"},"error":{"type":"string","description":"A brief, human-readable description of the error type (e.g., \"Internal Server Error\", \"Service Unavailable\").","example":"Internal Server Error"},"message":{"type":"string","description":"Additional details about the error.","example":"An unexpected error occurred. Please try again later."}}}}}}}}
>
  
</StatusCodes>


      