[GH-ISSUE #414] Parity: Certificate activation toggle (PATCH) #118

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

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

Overview

Add the ability to update certificate activation status.

Scope (OpenAPI resources)

  • PATCH /v1/certificates/{id} - updates activated boolean field

Proposed CLI

  • asc certificates update --id "CERT_ID" --activated true
  • asc certificates update --id "CERT_ID" --activated false

Examples:

  • asc certificates update --id "CERT_ID" --activated true
  • asc certificates update --id "CERT_ID" --activated false

Flag patterns

Common: --id, --activated, --output, --pretty

Output

  • JSON minified by default
  • --pretty for JSON

Detailed TODO

  • Add client method UpdateCertificate in internal/asc/client_signing.go
  • Add certificates update subcommand
  • Add HTTP client tests (mocked)
  • Add CLI cmdtests for flag validation

Acceptance criteria

  • Certificate activation status can be toggled via CLI

Tests

  • Flag validation tests
  • HTTP client test for PATCH endpoint

Implementation notes

  • The only updatable field is activated (boolean)
  • Follow existing patterns in internal/asc/client_signing.go

References

  • docs/openapi/paths.txt
  • docs/openapi/latest.json
  • internal/asc/client_signing.go
Originally created by @rudrankriyam on GitHub (Feb 2, 2026). Original GitHub issue: https://github.com/rudrankriyam/App-Store-Connect-CLI/issues/414 # Overview Add the ability to update certificate activation status. # Scope (OpenAPI resources) - `PATCH /v1/certificates/{id}` - updates `activated` boolean field # Proposed CLI - `asc certificates update --id "CERT_ID" --activated true` - `asc certificates update --id "CERT_ID" --activated false` Examples: - `asc certificates update --id "CERT_ID" --activated true` - `asc certificates update --id "CERT_ID" --activated false` # Flag patterns Common: `--id`, `--activated`, `--output`, `--pretty` # Output - JSON minified by default - `--pretty` for JSON # Detailed TODO - [ ] Add client method `UpdateCertificate` in `internal/asc/client_signing.go` - [ ] Add `certificates update` subcommand - [ ] Add HTTP client tests (mocked) - [ ] Add CLI cmdtests for flag validation # Acceptance criteria - [ ] Certificate activation status can be toggled via CLI # Tests - Flag validation tests - HTTP client test for PATCH endpoint # Implementation notes - The only updatable field is `activated` (boolean) - Follow existing patterns in `internal/asc/client_signing.go` # References - `docs/openapi/paths.txt` - `docs/openapi/latest.json` - `internal/asc/client_signing.go`
kerem closed this issue 2026-02-26 21:33:34 +03:00
Author
Owner

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

@cursor please implement this issue. Add the UpdateCertificate client method and the CLI command to toggle the activated flag.

<!-- gh-comment-id:3837591508 --> @rudrankriyam commented on GitHub (Feb 2, 2026): @cursor please implement this issue. Add the UpdateCertificate client method and the CLI command to toggle the activated flag.
Author
Owner

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

Summary:

  • I added certificate activation update support end-to-end: new UpdateCertificate client method + request types (including activated in certificate attributes), plus a new asc certificates update --id ... --activated true|false CLI subcommand and help examples.
  • I added HTTP client coverage for the PATCH payload and CLI flag-validation coverage (cmdtest + package-level tests).

Tests:

  • make test
  • Recorded: go test ./internal/asc -run TestUpdateCertificate_SendsRequest and go test ./internal/cli/cmdtest -run TestCertificatesValidationErrors

Walkthrough artifact:

  • /opt/cursor/artifacts/certificates_update_tests/recording_demo.mp4 (terminal run of the two targeted tests above).
    Note: the mediaReview tool was unavailable, so I couldn’t auto-verify the recording; this is based on the computer-use run report.

View PR
Open in Cursor Open in Web

<!-- gh-comment-id:3837591715 --> @cursor[bot] commented on GitHub (Feb 2, 2026): Summary: - I added certificate activation update support end-to-end: new `UpdateCertificate` client method + request types (including `activated` in certificate attributes), plus a new `asc certificates update --id ... --activated true|false` CLI subcommand and help examples. - I added HTTP client coverage for the PATCH payload and CLI flag-validation coverage (cmdtest + package-level tests). Tests: - `make test` - Recorded: `go test ./internal/asc -run TestUpdateCertificate_SendsRequest` and `go test ./internal/cli/cmdtest -run TestCertificatesValidationErrors` Walkthrough artifact: - `/opt/cursor/artifacts/certificates_update_tests/recording_demo.mp4` (terminal run of the two targeted tests above). Note: the mediaReview tool was unavailable, so I couldn’t auto-verify the recording; this is based on the computer-use run report. <a href="https://github.com/rudrankriyam/App-Store-Connect-CLI/pull/418"><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> <a href="https://cursor.com/background-agent?bcId=bc-8acf3543-86c9-4d60-8596-f002871d50eb"><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-8acf3543-86c9-4d60-8596-f002871d50eb"><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>
Author
Owner

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

Resolved in #418.

<!-- gh-comment-id:3840418183 --> @rudrankriyam commented on GitHub (Feb 3, 2026): Resolved in #418.
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#118
No description provided.