[GH-ISSUE #620] coverage: Add missing Xcode Cloud (CI/SCM) relationship endpoints (OpenAPI) #177

Closed
opened 2026-02-26 21:33:54 +03:00 by kerem · 3 comments
Owner

Originally created by @rudrankriyam on GitHub (Feb 18, 2026).
Original GitHub issue: https://github.com/rudrankriyam/App-Store-Connect-CLI/issues/620

Context

These endpoints exist in the offline OpenAPI snapshot (docs/openapi/latest.json, indexed by docs/openapi/paths.txt) but are currently missing from internal/asc client coverage.

Goal

Add ASC client methods for the endpoints below (method + path).

Missing endpoints

  • GET /v1/ciBuildActions/{id}/relationships/artifacts
  • GET /v1/ciBuildActions/{id}/relationships/buildRun
  • GET /v1/ciBuildActions/{id}/relationships/issues
  • GET /v1/ciBuildActions/{id}/relationships/testResults
  • GET /v1/ciBuildRuns/{id}/relationships/actions
  • GET /v1/ciBuildRuns/{id}/relationships/builds
  • GET /v1/ciMacOsVersions/{id}/relationships/xcodeVersions
  • GET /v1/ciProducts/{id}/relationships/additionalRepositories
  • GET /v1/ciProducts/{id}/relationships/app
  • GET /v1/ciProducts/{id}/relationships/buildRuns
  • GET /v1/ciProducts/{id}/relationships/primaryRepositories
  • GET /v1/ciProducts/{id}/relationships/workflows
  • GET /v1/ciWorkflows/{id}/relationships/buildRuns
  • GET /v1/ciWorkflows/{id}/relationships/repository
  • GET /v1/ciXcodeVersions/{id}/relationships/macOsVersions
  • GET /v1/scmProviders/{id}/relationships/repositories

Where/what to add

  • Implement in internal/asc/xcode_cloud.go (or a new internal/asc/client_xcode_cloud_relationships.go).
  • Relationship GETs should return LinkagesResponse with LinkagesOption support (limit/next).
  • Tests: request-shaping tests using newTestClient (method/path/query).

Test plan

  • Add request-shaping tests using newTestClient (assert method + path + query).
  • For mutation endpoints (POST/PATCH/DELETE), assert request method + path and (when applicable) JSON relationship payload shape.

Acceptance criteria

  • All endpoints listed are implemented in internal/asc with tests.
  • ASC_BYPASS_KEYCHAIN=1 make test passes.
Originally created by @rudrankriyam on GitHub (Feb 18, 2026). Original GitHub issue: https://github.com/rudrankriyam/App-Store-Connect-CLI/issues/620 ## Context These endpoints exist in the offline OpenAPI snapshot (`docs/openapi/latest.json`, indexed by `docs/openapi/paths.txt`) but are currently missing from `internal/asc` client coverage. ## Goal Add ASC client methods for the endpoints below (method + path). ## Missing endpoints - [ ] GET /v1/ciBuildActions/{id}/relationships/artifacts - [ ] GET /v1/ciBuildActions/{id}/relationships/buildRun - [ ] GET /v1/ciBuildActions/{id}/relationships/issues - [ ] GET /v1/ciBuildActions/{id}/relationships/testResults - [ ] GET /v1/ciBuildRuns/{id}/relationships/actions - [ ] GET /v1/ciBuildRuns/{id}/relationships/builds - [ ] GET /v1/ciMacOsVersions/{id}/relationships/xcodeVersions - [ ] GET /v1/ciProducts/{id}/relationships/additionalRepositories - [ ] GET /v1/ciProducts/{id}/relationships/app - [ ] GET /v1/ciProducts/{id}/relationships/buildRuns - [ ] GET /v1/ciProducts/{id}/relationships/primaryRepositories - [ ] GET /v1/ciProducts/{id}/relationships/workflows - [ ] GET /v1/ciWorkflows/{id}/relationships/buildRuns - [ ] GET /v1/ciWorkflows/{id}/relationships/repository - [ ] GET /v1/ciXcodeVersions/{id}/relationships/macOsVersions - [ ] GET /v1/scmProviders/{id}/relationships/repositories ## Where/what to add - Implement in `internal/asc/xcode_cloud.go` (or a new `internal/asc/client_xcode_cloud_relationships.go`). - Relationship GETs should return `LinkagesResponse` with `LinkagesOption` support (limit/next). - Tests: request-shaping tests using `newTestClient` (method/path/query). ## Test plan - Add request-shaping tests using `newTestClient` (assert method + path + query). - For mutation endpoints (POST/PATCH/DELETE), assert request method + path and (when applicable) JSON relationship payload shape. ## Acceptance criteria - All endpoints listed are implemented in `internal/asc` with tests. - `ASC_BYPASS_KEYCHAIN=1 make test` passes.
kerem 2026-02-26 21:33:54 +03:00
Author
Owner

@rudrankriyam commented on GitHub (Feb 18, 2026):

@cursor please implement this issue (#620).

Scope: 16 missing Xcode Cloud (CI/SCM) relationship endpoints (GET-only).

Implementation notes:

  • These are /v1/ci.../relationships/... and /v1/scm.../relationships/... endpoints.
  • Be careful about to-one vs to-many relationship linkages. Use LinkagesResponse for to-many; for to-one, use a single-linkage response shape (Data ResourceData) like existing BuildAppLinkageResponse patterns.
  • Add request-shaping tests for each endpoint (method + path + query).

Acceptance:

  • All endpoints in the issue checklist are implemented in internal/asc/ with tests.
  • ASC_BYPASS_KEYCHAIN=1 make test passes.
<!-- gh-comment-id:3918647097 --> @rudrankriyam commented on GitHub (Feb 18, 2026): @cursor please implement this issue (#620). Scope: 16 missing Xcode Cloud (CI/SCM) relationship endpoints (GET-only). Implementation notes: - These are `/v1/ci.../relationships/...` and `/v1/scm.../relationships/...` endpoints. - Be careful about to-one vs to-many relationship linkages. Use `LinkagesResponse` for to-many; for to-one, use a single-linkage response shape (`Data ResourceData`) like existing `BuildAppLinkageResponse` patterns. - Add request-shaping tests for each endpoint (method + path + query). Acceptance: - All endpoints in the issue checklist are implemented in `internal/asc/` with tests. - `ASC_BYPASS_KEYCHAIN=1 make test` passes.
Author
Owner

@cursor[bot] commented on GitHub (Feb 18, 2026):

Implemented issue #620: added ASC client coverage + request-shaping tests for the 16 missing Xcode Cloud (CI/SCM) GET relationship endpoints.

What I added

  • New client methods in internal/asc/client_xcode_cloud_relationships.go:

    • To-many relationship endpoints return *LinkagesResponse and accept ...LinkagesOption (limit/next):
      • GET /v1/ciBuildActions/{id}/relationships/artifacts
      • GET /v1/ciBuildActions/{id}/relationships/issues
      • GET /v1/ciBuildActions/{id}/relationships/testResults
      • GET /v1/ciBuildRuns/{id}/relationships/actions
      • GET /v1/ciBuildRuns/{id}/relationships/builds
      • GET /v1/ciMacOsVersions/{id}/relationships/xcodeVersions
      • GET /v1/ciProducts/{id}/relationships/additionalRepositories
      • GET /v1/ciProducts/{id}/relationships/buildRuns
      • GET /v1/ciProducts/{id}/relationships/primaryRepositories
      • GET /v1/ciProducts/{id}/relationships/workflows
      • GET /v1/ciWorkflows/{id}/relationships/buildRuns
      • GET /v1/ciXcodeVersions/{id}/relationships/macOsVersions
      • GET /v1/scmProviders/{id}/relationships/repositories
    • To-one relationship endpoints return single-linkage response shapes (Data ResourceData) via new types:
      • GET /v1/ciBuildActions/{id}/relationships/buildRunCiBuildActionBuildRunLinkageResponse
      • GET /v1/ciProducts/{id}/relationships/appCiProductAppLinkageResponse
      • GET /v1/ciWorkflows/{id}/relationships/repositoryCiWorkflowRepositoryLinkageResponse
  • New request-shaping tests in internal/asc/client_http_xcode_cloud_relationships_test.go asserting method + path + query (limit) and next URL passthrough for each to-many endpoint, plus basic GET/path checks for the 3 to-one endpoints.

Verification

  • ASC_BYPASS_KEYCHAIN=1 make test
  • make lint

View PR

Open in Cursor Open in Web

<!-- gh-comment-id:3918647674 --> @cursor[bot] commented on GitHub (Feb 18, 2026): Implemented issue #620: added ASC client coverage + request-shaping tests for the 16 missing Xcode Cloud (CI/SCM) **GET** relationship endpoints. ### What I added - New client methods in `internal/asc/client_xcode_cloud_relationships.go`: - **To-many** relationship endpoints return `*LinkagesResponse` and accept `...LinkagesOption` (limit/next): - `GET /v1/ciBuildActions/{id}/relationships/artifacts` - `GET /v1/ciBuildActions/{id}/relationships/issues` - `GET /v1/ciBuildActions/{id}/relationships/testResults` - `GET /v1/ciBuildRuns/{id}/relationships/actions` - `GET /v1/ciBuildRuns/{id}/relationships/builds` - `GET /v1/ciMacOsVersions/{id}/relationships/xcodeVersions` - `GET /v1/ciProducts/{id}/relationships/additionalRepositories` - `GET /v1/ciProducts/{id}/relationships/buildRuns` - `GET /v1/ciProducts/{id}/relationships/primaryRepositories` - `GET /v1/ciProducts/{id}/relationships/workflows` - `GET /v1/ciWorkflows/{id}/relationships/buildRuns` - `GET /v1/ciXcodeVersions/{id}/relationships/macOsVersions` - `GET /v1/scmProviders/{id}/relationships/repositories` - **To-one** relationship endpoints return single-linkage response shapes (`Data ResourceData`) via new types: - `GET /v1/ciBuildActions/{id}/relationships/buildRun` → `CiBuildActionBuildRunLinkageResponse` - `GET /v1/ciProducts/{id}/relationships/app` → `CiProductAppLinkageResponse` - `GET /v1/ciWorkflows/{id}/relationships/repository` → `CiWorkflowRepositoryLinkageResponse` - New request-shaping tests in `internal/asc/client_http_xcode_cloud_relationships_test.go` asserting **method + path + query** (limit) and **next URL passthrough** for each to-many endpoint, plus basic GET/path checks for the 3 to-one endpoints. ### Verification - `ASC_BYPASS_KEYCHAIN=1 make test` ✅ - `make lint` ✅ <p><a href="https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/627"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/view-pr-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/view-pr-light.png"><img alt="View PR" width="86" height="28" src="https://cursor.com/assets/images/view-pr-light.png"></picture></a></p> <p><a href="https://cursor.com/background-agent?bcId=bc-99fb78b2-efbe-4f43-b197-e3a5a46cd7ca"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-cursor-light.png"><img alt="Open in Cursor" width="131" height="28" src="https://cursor.com/assets/images/open-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?id=bc-99fb78b2-efbe-4f43-b197-e3a5a46cd7ca"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-web-light.png"><img alt="Open in Web" width="114" height="28" src="https://cursor.com/assets/images/open-in-web-dark.png"></picture></a></p>
Author
Owner

@rudrankriyam commented on GitHub (Feb 18, 2026):

Closed by PR #627 (merged).

<!-- gh-comment-id:3919363407 --> @rudrankriyam commented on GitHub (Feb 18, 2026): Closed by PR #627 (merged).
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/App-Store-Connect-CLI#177
No description provided.