Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions integration-proxy/src/identity_catalog_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -346,3 +346,55 @@ async fn google_tasks_readonly_profile_is_scoped_and_proxy_compatible() {
)
.is_none());
}

/// Prepared ClickUp catalog: proxy-only read restrictions, no invented provider
/// scope. Pagination is blocked pending openapi-extensions#25; this is not a
/// claim of complete import or live OAuth certification.
#[tokio::test]
#[ignore = "downloads pinned candidate sources; set CLICKUP_CATALOG_URL for Pages"]
async fn clickup_read_profile_is_proxy_compatible_without_invented_scopes() {
let client = crate::build_http_client();
let catalog = if let Ok(url) = std::env::var("CLICKUP_CATALOG_URL") {
Catalog::load(&url, &client).await
} else {
Catalog::load_checked_in_file(&client, "catalog/2026-10-08-gitlab-tasks-clickup.json").await
}
.expect("prepared catalog pins must compose");
let provider = catalog
.oauth_provider("clickup")
.expect("ClickUp OAuth metadata must parse");
assert_eq!(provider.authorization_url, "https://app.clickup.com/api");
assert_eq!(
provider.token_url,
"https://api.clickup.com/api/v2/oauth/token"
);
assert!(
provider.scopes.is_empty(),
"ClickUp declares no selectable scopes"
);
assert!(
!provider.use_pkce,
"PKCE support is not documented by ClickUp"
);
for path in [
"/api/v2/team",
"/api/v2/team/123/task",
"/api/v2/task/task-1",
] {
assert!(catalog.allows("clickup", "GET", path).is_some());
for method in ["POST", "PUT", "PATCH", "DELETE"] {
assert!(catalog.allows("clickup", method, path).is_none());
}
}
assert!(catalog.allows("clickup", "GET", "/api/v2/user").is_none());
catalog
.validate_request(
"clickup",
"GET",
"/api/v2/team/123/task",
Some("page=0"),
None,
false,
)
.expect("zero-based page request must validate");
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
overlay: 1.0.0
extends: https://raw.githubusercontent.com/ontola/openapi-directory/de95e5bf40f54e3752281a771a786854038d683b/APIs/clickup.com/v2-readonly/openapi.yaml
info:
title: ClickUp read-only OAuth authentication profile
version: 1.0.0
description: >-
Select the documented OAuth authorization-code flow for reads from
authorized Workspaces. ClickUp tokens grant the Workspaces selected by
the user and do not have selectable scopes; this profile limits the
declared operations to reads but does not narrow the provider token.
OAuth behavior checked against ClickUp's authentication documentation on
2026-10-08.
actions:
- target: $.components.securitySchemes
update:
clickupReadOnlyOAuth:
type: oauth2
x-oauth-authentication-details:
authorizationServerMetadata:
token_endpoint_auth_methods_supported: [client_secret_post]
authorizationCode:
pkce:
requirement: unsupported
flows:
authorizationCode:
authorizationUrl: https://app.clickup.com/api
tokenUrl: https://api.clickup.com/api/v2/oauth/token
scopes: {}
- target: $.paths['/v2/team'].get
update:
security:
- clickupReadOnlyOAuth: []
- target: $.paths['/v2/team/{team_Id}/task'].get
update:
security:
- clickupReadOnlyOAuth: []
- target: $.paths['/v2/task/{task_id}'].get
update:
security:
- clickupReadOnlyOAuth: []
- target: $.components
update:
x-authentication-profiles:
clickupReadOnly:
securityScheme: clickupReadOnlyOAuth
description: >-
Read the authorized Workspace list and tasks the user can access.
The provider authorization may cover one or more Workspaces and does
not expose a read-only OAuth scope.
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
overlay: 1.0.0
extends: https://raw.githubusercontent.com/ontola/openapi-directory/de95e5bf40f54e3752281a771a786854038d683b/APIs/clickup.com/v2-readonly/openapi.yaml
info:
title: ClickUp Workspace and task read causality
version: 1.0.0
description: >-
Model authorized Workspaces as the root collection and tasks as a
Workspace-scoped child collection. Task.parent remains the provider's
subtask field; it does not imply separate subtask CRUD resources.
actions:
- target: $.components
update:
crudResources:
workspace:
description: A Workspace authorized for the current user.
identity:
# ClickUp has no Workspace item-read endpoint. This identity template
# carries the Workspace id into its child collection request.
urlTemplate: /v2/team/{team_Id}
bindings:
team_Id:
field: id
collections:
workspaces:
urlTemplate: /v2/team
envelope:
itemsField: teams
task:
description: A task the authenticated user can access in a Workspace.
identity:
urlTemplate: /v2/task/{task_id}
bindings:
task_id:
field: id
collections:
workspaceTasks:
urlTemplate: /v2/team/{team_Id}/task
envelope:
itemsField: tasks
- target: $.paths['/v2/team'].get
update:
x-crud:
action: list
resource: workspace
collection: workspaces
- target: $.paths['/v2/team/{team_Id}/task'].get
update:
x-crud:
action: list
resource: task
collection: workspaceTasks
- target: $.paths['/v2/task/{task_id}'].get
update:
x-crud:
action: read
resource: task
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
overlay: 1.0.0
extends: https://raw.githubusercontent.com/ontola/openapi-directory/de95e5bf40f54e3752281a771a786854038d683b/APIs/clickup.com/v2-readonly/openapi.yaml
info:
title: ClickUp filtered Workspace task pagination
version: 1.0.0
description: >-
Pagination Schemes 0.6.0: ClickUp documents zero-based page numbers
("Page to fetch (starts at 0)") and "Responses are limited to 100 tasks
per page"; the response holds only `tasks`, with no continuation or
count field. The page role starts at 0, and a page with fewer than 100
tasks ends the list. ClickUp does not document that a short page is
the last one, so the end is assumed: a read is not complete, and no
absence is inferred from it.
actions:
- target: $.components
update:
paginationSchemes:
workspaceTaskPages:
type: pageNumber
autoDetect: false
description: >-
page starts at 0; responses are limited to 100 tasks per page; the
response has no continuation or count field
(https://developer.clickup.com/reference/getfilteredteamtasks,
checked 2026-10-08).
request:
queryParameters:
page:
role: page
start: 0
response:
envelope:
itemsField: tasks
shortPage:
size: 100
assurance: assumed
description: >-
The reference documents only "Responses are limited to 100 tasks
per page"; it does not say that a short page is the last one.
- target: $.paths['/v2/team/{team_Id}/task'].get
update:
x-pagination:
- scheme: workspaceTaskPages
17 changes: 17 additions & 0 deletions overlays/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1631,6 +1631,23 @@ the proxy parser. The Google Tasks importer fixture is
`tests/google_tasks_syncables.test.ts`; its composition checks are
`tests/test_google_tasks_readonly.py`. Real-account sync is not certified.

## ClickUp preparation

`catalog/2026-10-08-gitlab-tasks-clickup.json` is a prepared fourteen-entry
candidate. It preserves the thirteen GitLab/Google Tasks entries and adds
three ClickUp GET operations. Task pages follow Pagination Schemes 0.6.0:
`page` starts at 0, and a page with fewer than 100 tasks ends the list, with
`assurance: assumed`, since ClickUp documents only the 100-task cap. Every
task read is therefore not complete, and no deletion is inferred from it.
Consumer validation passes with published Syncables 0.25.0 on Node 22 and
the current repository source. Use that verified release: the published
0.21.0 package still asks for page 1 first and skips page 0.

ClickUp OAuth has no selectable read scopes; the proxy profile limits reads
to these three operations, while the provider token can have broader access
to selected Workspaces. OAuth client registration and a real account grant
are pending. This candidate is not complete synchronization certification.

## Google Tasks deployment without GitLab

`catalog/2026-10-08-google-tasks.json` preserves all eleven production entries
Expand Down
Loading
Loading