Project (classic) 열
Use the REST API to create and manage columns on a classic project.
Notes:
- These endpoints only interact with projects (classic). To manage Projects, use the GraphQL API. For more information, see "Using the API to manage Projects."
- To create a new classic project, the organization, user, or repository must already have at least one classic project.
The REST API to manage projects (classic) only supports authentication using a personal access token (classic). For more information, see "Managing your personal access tokens."
Get a project column
Gets information about a project column.
"Get a project column"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
column_id integer RequiredThe unique identifier of the column. |
"Get a project column"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
200 | OK |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
404 | Resource not found |
"Get a project column"에 대한 코드 샘플
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/columns/COLUMN_ID
Response
Status: 200
{
"url": "https://api.github.com/projects/columns/367",
"project_url": "https://api.github.com/projects/120",
"cards_url": "https://api.github.com/projects/columns/367/cards",
"id": 367,
"node_id": "MDEzOlByb2plY3RDb2x1bW4zNjc=",
"name": "To Do",
"created_at": "2016-09-05T14:18:44Z",
"updated_at": "2016-09-05T14:22:28Z"
}
Update an existing project column
"Update an existing project column"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
column_id integer RequiredThe unique identifier of the column. |
이름, Type, 설명 |
---|
name string RequiredName of the project column |
"Update an existing project column"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
200 | OK |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
"Update an existing project column"에 대한 코드 샘플
curl -L \
-X PATCH \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/columns/COLUMN_ID \
-d '{"name":"To Do"}'
Response
Status: 200
{
"url": "https://api.github.com/projects/columns/367",
"project_url": "https://api.github.com/projects/120",
"cards_url": "https://api.github.com/projects/columns/367/cards",
"id": 367,
"node_id": "MDEzOlByb2plY3RDb2x1bW4zNjc=",
"name": "To Do",
"created_at": "2016-09-05T14:18:44Z",
"updated_at": "2016-09-05T14:22:28Z"
}
Delete a project column
Deletes a project column.
"Delete a project column"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
column_id integer RequiredThe unique identifier of the column. |
"Delete a project column"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
204 | No Content |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
"Delete a project column"에 대한 코드 샘플
curl -L \
-X DELETE \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/columns/COLUMN_ID
Response
Status: 204
Move a project column
"Move a project column"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
column_id integer RequiredThe unique identifier of the column. |
이름, Type, 설명 |
---|
position string RequiredThe position of the column in a project. Can be one of: |
"Move a project column"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
201 | Created |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
422 | Validation failed, or the endpoint has been spammed. |
"Move a project column"에 대한 코드 샘플
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/columns/COLUMN_ID/moves \
-d '{"position":"last"}'
Response
List project columns
Lists the project columns in a project.
"List project columns"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
project_id integer RequiredThe unique identifier of the project. |
이름, Type, 설명 |
---|
per_page integer The number of results per page (max 100). 기본값: |
page integer Page number of the results to fetch. 기본값: |
"List project columns"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
200 | OK |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
"List project columns"에 대한 코드 샘플
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/PROJECT_ID/columns
Response
Status: 200
[
{
"url": "https://api.github.com/projects/columns/367",
"project_url": "https://api.github.com/projects/120",
"cards_url": "https://api.github.com/projects/columns/367/cards",
"id": 367,
"node_id": "MDEzOlByb2plY3RDb2x1bW4zNjc=",
"name": "To Do",
"created_at": "2016-09-05T14:18:44Z",
"updated_at": "2016-09-05T14:22:28Z"
}
]
Create a project column
Creates a new project column.
"Create a project column"에 대한 매개 변수
이름, Type, 설명 |
---|
accept string Setting to |
이름, Type, 설명 |
---|
project_id integer RequiredThe unique identifier of the project. |
이름, Type, 설명 |
---|
name string RequiredName of the project column |
"Create a project column"에 대한 HTTP 응답 상태 코드
상태 코드 | 설명 |
---|---|
201 | Created |
304 | Not modified |
401 | Requires authentication |
403 | Forbidden |
422 | Validation failed, or the endpoint has been spammed. |
"Create a project column"에 대한 코드 샘플
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/projects/PROJECT_ID/columns \
-d '{"name":"Remaining tasks"}'
Response
Status: 201
{
"url": "https://api.github.com/projects/columns/367",
"project_url": "https://api.github.com/projects/120",
"cards_url": "https://api.github.com/projects/columns/367/cards",
"id": 367,
"node_id": "MDEzOlByb2plY3RDb2x1bW4zNjc=",
"name": "To Do",
"created_at": "2016-09-05T14:18:44Z",
"updated_at": "2016-09-05T14:22:28Z"
}