Files
rickyandClaude Opus 5.5 bffdea937c REST API v1: tokens, read endpoints, squawks, webhooks
- Personal tokens (Profile → API tokens) act as their owner; integration
  tokens (Admin → Integrations) reach chosen aircraft and scopes, and their
  writes name the person they're for (SAM-On-Behalf-Of). Tokens are stored
  hashed, shown once, revocable, with last use recorded.
- GET aircraft, components, due list, inspections, ADs, logbook entries and
  squawks; POST/PATCH squawks with external_ref links to the other system.
- Idempotency-Key for safe retries, paging, JSON errors, rate limits.
- Record history keeps the token with each change (in the hashed payload).
- Webhooks (squawk created/updated/resolved, entry signed), HMAC-signed,
  retried, never sent to the server itself; deliveries listed for admins.
- The outbound address check is shared by AirTrail and webhooks; reporting a
  squawk is announced the same way from the form and the API.
- docs/guide/api.md: the API reference.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 19:05:10 -05:00

16 lines
805 B
ERB

<% content_for :title, @integration.name %>
<section class="card card-body max-w-xl space-y-3">
<h1 class="card-title"><%= @integration.name %></h1>
<p class="text-sm text-slate-600"><%= t(".copy_now") %></p>
<% if @integration.token %>
<label class="label" for="integration_token"><%= t(".token") %></label>
<input id="integration_token" class="input font-mono text-sm" value="<%= @integration.token %>" readonly>
<% end %>
<% if @secret %>
<label class="label" for="webhook_secret"><%= t(".webhook_secret") %></label>
<input id="webhook_secret" class="input font-mono text-sm" value="<%= @secret %>" readonly>
<p class="hint"><%= t(".secret_hint") %></p>
<% end %>
<p><%= link_to t(".done"), admin_integration_path(@integration), class: "btn-primary" %></p>
</section>