# Update Pathway

Update the pathway, where you can update the pathway's name, code, and description information based on the pathway's ID.

**Notice**：Non-required fields, no changes will be made when not passed on

## Request

Facts | &nbsp;
---|---
HTTP URL | https://open.feishu.cn/open-apis/corehr/v2/pathways/:pathway_id
HTTP Method | PATCH
Rate Limit | [3 per second](https://open.feishu.cn/document/ukTMukTMukTM/uUzN04SN3QjL1cDN)
Supported app types | Custom App、Store App
Required scopes<br>**To use this API, you must have at least 1 of the listed scopes.** | Read and write pathway information(corehr:pathway:write)

### Request header

Parameter | Type | Required | Description
---|---|---|---
Authorization | string | Yes | `tenant_access_token`<br>**Value format**: "Bearer `access_token`"<br>**Example value**: "Bearer t-7f1bcd13fc57d46bac21793a18e560"<br>[How to choose and get access token](https://open.feishu.cn/document/uAjLw4CM/ugTN1YjL4UTN24CO1UjN/trouble-shooting/how-to-choose-which-type-of-token-to-use)
Content-Type | string | Yes | **Fixed value**: "application/json; charset=utf-8"

### Path parameters

Parameter | Type | Description
---|---|---
pathway_id | string | Pathway ID. ID acquisition method<br>- After calling [create pathway interface](/document-mod/index?fullPath=%2FuAjLw4CM%2FukTMukTMukTM%2Fcorehr-v2%2Fpathway%2Fcreate), obtain it from `pathway_id` in the response result.<br>- Listen to [pathway creation event](/document-mod/index?fullPath=/uAjLw4CM/ukTMukTMukTM/corehr-v2/pathway/events/created), when the event is triggered, you can get `pathway_id` from the event body<br>- Listen to [pathway update event](/document-mod/index?fullPath=/uAjLw4CM/ukTMukTMukTM/corehr-v2/pathway/events/updated), when the event is triggered, you can get `pathway_id` from the event body<br>- Listen to [pathway deletion event](/document-mod/index?fullPath=%2FuAjLw4CM%2FukTMukTMukTM%2Fcorehr-v2%2Fpathway%2Fevents%2Fdeleted), when the event is triggered, you can get `pathway_id` from the event body<br>**Example value**: "6862995757234914824"

### Query parameters

Parameter | Type | Required | Description
---|---|---|---
client_token | string | No | Determine whether the same request is based on whether the client_token are consistent<br>**Example value**: 1245464678<br>**Data validation rules**:<br>- Length range: `0` ～ `128` characters

### Request body

Parameter | Type | Required | Description
---|---|---|---
code | string | No | code<br>**Example value**: "A01234"
names | i18n\[\] | No | name<br>**Data validation rules**:<br>- Length range: `0` ～ `2`
lang | string | Yes | zh-CN for Chinese, en-US for English.<br>**Example value**: "zh-CN"
value | string | Yes | - The text content supports a maximum of 255 characters.<br>- The name cannot contain the characters: /, ;, \, and '.<br>**Example value**: "中文示例"
descriptions | i18n\[\] | No | describe<br>**Data validation rules**:<br>- Length range: `0` ～ `2`
lang | string | Yes | zh-CN for Chinese, en-US for English.<br>**Example value**: "zh-CN"
value | string | Yes | The text content supports a maximum of 2000 characters.<br>**Example value**: "中文示例"

### Request body example
```json
{
    "code": "A01234",
    "names": [
        {
            "lang": "zh-CN",
            "value": "中文示例"
        }
    ],
    "descriptions": [
        {
            "lang": "zh-CN",
            "value": "中文示例"
        }
    ]
}
```

## Response

### Response body

Parameter | Type | Description
---|---|---
code | int | Error codes, fail if not zero
msg | string | Error descriptions
data | \- | \-

### Response body example
```json
{
    "code": 0,
    "msg": "success",
    "data": {}
}
```

### Error code

HTTP status code | Error code | Description | Troubleshooting suggestions
---|---|---|---
429 | 1161604 | QPS over limit | Please refer to the detailed description of the full number of error codes for error troubleshooting. If the problem cannot be solved, please contact [Technical Support](https://applink.feishu.cn/TLJpeNdW)

Other Error Code Reference: [Detailed Description of Full Error Codes](/document-mod/index?fullPath=%2FuAjLw4CM%2FukTMukTMukTM%2Fcorehr-v2%2Fpathway%2Fpathway-errorcodes)

