Approve the authorization (merchant consent)
Called by the Galactic Core consent page after the merchant clicks Authorize. Provisions a key pair for the selected store, records the connection, and returns the redirect URL the browser should follow to complete the flow.
An agency-scoped application can be authorized only by a store that
belongs to that agency; a store outside the agency receives 403.
Authentication: The merchant’s active Galactic Core session JWT in
the Authorization: Bearer header. This is not an API key — it is the
session token issued by the GC login flow.
Rate limit: 20 requests/hour per IP address.
This endpoint is called by the hosted consent page — you do not call it directly from your integration.
Authorizations
API Key Authentication
Use your API key in the Authorization header:
Key Types:
Secret Keys (Server-Side Only):
- Format:
tybrite_sk_live_*(production) ortybrite_sk_test_*(sandbox) - Full read/write access to all endpoints
- ⚠️ NEVER expose in client-side code or public repositories
- Required for: write operations, authentication, payment verification, AI recommendations
Publishable Keys (Client-Safe):
- Format:
tybrite_pk_live_*(production) ortybrite_pk_test_*(sandbox) - Read-only access (GET requests only, plus POST semantic search)
- ✅ Safe for client-side JavaScript, mobile apps, and public code
- Allowed for: browsing products, search, CMS content, pricing queries
Endpoint-Specific Requirements:
- Authentication endpoints (
/v1/auth/*): Secret key required - Payment verification (
POST /v1/payments/verify): Secret key required - AI Recommendations (
POST /v1/recommendations): Secret key required - Semantic Search (
POST /v1/search): Both key types allowed (read-only operation) - All write operations: Secret key required
- All read operations: Both key types allowed
Using a publishable key for restricted operations returns 403 Forbidden.
Body
Registered client identifier.
"fantastic-storefront"
Must match the URI from the original GET request.
"https://yourapp.com/callback"
Space-separated list of scopes from the original GET request.
"read orders:read"
CSRF token from the original GET request.
"a8f3d2e1c9b7"
Environment for the provisioned key pair.
sandbox, production "sandbox"
UUID of the store the merchant is authorizing access to.
"550e8400-e29b-41d4-a716-446655440000"
Response
Authorization approved — redirect the browser to redirect_to
The URL to redirect the merchant's browser to. Contains a
short-lived one-time code and the original state value.
"https://yourapp.com/callback?code=abc123def456&state=a8f3d2e1c9b7"

