Bootstrap copied BFF and local accounts with public Sendico contracts (#34)
This commit is contained in:
1 parent
67dc5b5b1e
commit
7062672a87
556 files changed
+42291
-777
No files matched your search
@@ -0,0 +1,37 @@
|
||||
get:
|
||||
tags: [Callbacks]
|
||||
summary: Archive/unarchive callback subscription
|
||||
description: Sets callback archive state by `callbacks_ref` and required `archived` query parameter.
|
||||
operationId: callbacksArchive
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/org_ref.yaml#/components/parameters/OrgRef
|
||||
- $ref: ../parameters/callbacks_ref.yaml#/components/parameters/CallbacksRef
|
||||
- name: archived
|
||||
in: query
|
||||
required: true
|
||||
description: Target archive value to set on the callback.
|
||||
schema:
|
||||
type: boolean
|
||||
- $ref: ../parameters/cascade.yaml#/components/parameters/Cascade
|
||||
responses:
|
||||
'200':
|
||||
description: Archive state updated
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
@@ -0,0 +1,17 @@
|
||||
components:
|
||||
requestBodies:
|
||||
CallbackCreateBody:
|
||||
description: JSON body containing callback endpoint configuration for create.
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: ../request/callback.yaml#/components/schemas/CallbackCreateRequest
|
||||
|
||||
CallbackUpdateBody:
|
||||
description: JSON body containing callback endpoint configuration for update.
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: ../request/callback.yaml#/components/schemas/CallbackUpdateRequest
|
||||
@@ -0,0 +1,33 @@
|
||||
post:
|
||||
tags: [Callbacks]
|
||||
summary: Create callback subscription
|
||||
description: Creates callback subscription for the organization identified by `org_ref`.
|
||||
operationId: callbacksCreate
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/org_ref.yaml#/components/parameters/OrgRef
|
||||
requestBody:
|
||||
$ref: ./bodies/callback.yaml#/components/requestBodies/CallbackCreateBody
|
||||
responses:
|
||||
'201':
|
||||
description: Callback created
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'409':
|
||||
$ref: ../response/operation.yaml#/components/responses/Conflict
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
@@ -0,0 +1,35 @@
|
||||
get:
|
||||
tags: [Callbacks]
|
||||
summary: List callback subscriptions
|
||||
description: |
|
||||
Lists callbacks for the given organization context.
|
||||
The route currently includes both `org_ref` and `organizations_ref`; the handler resolves organization context from `org_ref` and ignores `organizations_ref`.
|
||||
operationId: callbacksList
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/org_ref.yaml#/components/parameters/OrgRef
|
||||
- $ref: ../parameters/organizations_ref.yaml#/components/parameters/OrganizationsRef
|
||||
- $ref: ../parameters/limit.yaml#/components/parameters/Limit
|
||||
- $ref: ../parameters/offset.yaml#/components/parameters/Offset
|
||||
- $ref: ../parameters/archived.yaml#/components/parameters/Archived
|
||||
responses:
|
||||
'200':
|
||||
description: Callback list
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
@@ -0,0 +1,64 @@
|
||||
get:
|
||||
tags: [Callbacks]
|
||||
summary: Get callback subscription
|
||||
description: Returns callback subscription by `callbacks_ref`.
|
||||
operationId: callbacksGet
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/callbacks_ref.yaml#/components/parameters/CallbacksRef
|
||||
responses:
|
||||
'200':
|
||||
description: Callback data
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'404':
|
||||
$ref: ../response/operation.yaml#/components/responses/NotFound
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
|
||||
delete:
|
||||
tags: [Callbacks]
|
||||
summary: Delete callback subscription
|
||||
description: Deletes callback by reference.
|
||||
operationId: callbacksDelete
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/callbacks_ref.yaml#/components/parameters/CallbacksRef
|
||||
- $ref: ../parameters/cascade.yaml#/components/parameters/Cascade
|
||||
responses:
|
||||
'200':
|
||||
description: Callback deleted
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'404':
|
||||
$ref: ../response/operation.yaml#/components/responses/NotFound
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
@@ -0,0 +1,113 @@
|
||||
components:
|
||||
schemas:
|
||||
CallbackBackoffInput:
|
||||
description: Optional retry backoff overrides. Non-positive values currently fall back to server defaults.
|
||||
type: object
|
||||
additionalProperties: false
|
||||
properties:
|
||||
minDelayMs:
|
||||
type: integer
|
||||
maxDelayMs:
|
||||
type: integer
|
||||
|
||||
CallbackRetryPolicyInput:
|
||||
description: Optional retry and signing overrides. Omitted or non-positive numeric values currently fall back to server defaults.
|
||||
type: object
|
||||
additionalProperties: false
|
||||
properties:
|
||||
backoff:
|
||||
$ref: '#/components/schemas/CallbackBackoffInput'
|
||||
signingMode:
|
||||
description: |
|
||||
Optional signing mode. Canonical values are documented here; current handler also accepts legacy aliases such as `hmac`, `hmac-sha256`, `jws-eddsa-ed25519`, `jws+eddsa-ed25519`, `jws_eddsa`, and `eddsa_ed25519`.
|
||||
type: string
|
||||
enum:
|
||||
- none
|
||||
- hmac_sha256
|
||||
- jws_eddsa_ed25519
|
||||
headers:
|
||||
type: object
|
||||
additionalProperties:
|
||||
type: string
|
||||
maxAttempts:
|
||||
type: integer
|
||||
requestTimeoutMs:
|
||||
type: integer
|
||||
|
||||
CallbackCreateRequest:
|
||||
description: |
|
||||
Request payload used to create a callback configuration.
|
||||
Only `url` is hard-required by current create logic. Other mutable fields are optional and defaulted by the handler when omitted.
|
||||
type: object
|
||||
additionalProperties: false
|
||||
required:
|
||||
- url
|
||||
properties:
|
||||
name:
|
||||
description: Optional callback display name. When omitted, the handler defaults it to `url`.
|
||||
type: string
|
||||
description:
|
||||
description: Optional callback description.
|
||||
type: string
|
||||
nullable: true
|
||||
status:
|
||||
description: |
|
||||
Optional callback status. Canonical values are documented here; current handler also accepts `enabled` and `inactive` aliases.
|
||||
type: string
|
||||
enum:
|
||||
- active
|
||||
- disabled
|
||||
url:
|
||||
description: Absolute HTTPS callback endpoint URL.
|
||||
type: string
|
||||
format: uri
|
||||
eventTypes:
|
||||
description: Optional callback event types. When omitted or empty, the handler defaults this list.
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
retryPolicy:
|
||||
$ref: '#/components/schemas/CallbackRetryPolicyInput'
|
||||
|
||||
CallbackUpdateRequest:
|
||||
description: |
|
||||
Request payload used to update a callback configuration.
|
||||
The current PUT handler requires `id`, `organizationRef`, and `url`. Other mutable fields are optional, but omitted values may be reset to handler defaults during normalization.
|
||||
type: object
|
||||
additionalProperties: false
|
||||
required:
|
||||
- id
|
||||
- organizationRef
|
||||
- url
|
||||
properties:
|
||||
id:
|
||||
description: Callback identifier to update.
|
||||
$ref: ../../../models/objectid.yaml#/components/schemas/ObjectId
|
||||
organizationRef:
|
||||
description: Organization identifier carried in the stored callback record and currently required by the update path.
|
||||
$ref: ../../../models/objectid.yaml#/components/schemas/ObjectId
|
||||
name:
|
||||
description: Optional callback display name. When omitted, the handler defaults it to `url`.
|
||||
type: string
|
||||
description:
|
||||
description: Optional callback description.
|
||||
type: string
|
||||
nullable: true
|
||||
status:
|
||||
description: |
|
||||
Optional callback status. Canonical values are documented here; current handler also accepts `enabled` and `inactive` aliases.
|
||||
type: string
|
||||
enum:
|
||||
- active
|
||||
- disabled
|
||||
url:
|
||||
description: Absolute HTTPS callback endpoint URL.
|
||||
type: string
|
||||
format: uri
|
||||
eventTypes:
|
||||
description: Optional callback event types. When omitted or empty, the handler defaults this list.
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
retryPolicy:
|
||||
$ref: '#/components/schemas/CallbackRetryPolicyInput'
|
||||
@@ -0,0 +1,22 @@
|
||||
components:
|
||||
schemas:
|
||||
CallbacksAuthData:
|
||||
description: Authenticated response payload containing callback configurations.
|
||||
type: object
|
||||
additionalProperties: false
|
||||
required:
|
||||
- accessToken
|
||||
- callbacks
|
||||
properties:
|
||||
accessToken:
|
||||
description: Refreshed access token to be used in subsequent API calls.
|
||||
$ref: ../../../models/auth/token_data.yaml#/components/schemas/TokenData
|
||||
callbacks:
|
||||
description: Collection of callbacks configured for the authenticated scope. JWS-signed callbacks expose read-only verification JWKs via `callbacks[].signingKeys`.
|
||||
type: array
|
||||
items:
|
||||
$ref: ../../../models/callback/callback.yaml#/components/schemas/Callback
|
||||
generatedSigningSecret:
|
||||
description: Newly generated signing secret when HMAC signing material is created or rotated. JWS-signed callbacks do not populate this field.
|
||||
type: string
|
||||
nullable: true
|
||||
@@ -0,0 +1,31 @@
|
||||
post:
|
||||
tags: [Callbacks]
|
||||
summary: Rotate callback signing material
|
||||
description: Rotates the active signing material for the callback. HMAC callbacks generate and return a new shared secret once. `jws_eddsa_ed25519` callbacks generate a new Ed25519 keypair, expose the new active verification JWK on normal callback reads, and keep retiring verification keys visible for 24 hours.
|
||||
operationId: callbacksRotateSecret
|
||||
security:
|
||||
- bearerAuth: []
|
||||
parameters:
|
||||
- $ref: ../parameters/callbacks_ref.yaml#/components/parameters/CallbacksRef
|
||||
responses:
|
||||
'200':
|
||||
description: Callback signing material rotated
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'404':
|
||||
$ref: ../response/operation.yaml#/components/responses/NotFound
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
@@ -0,0 +1,31 @@
|
||||
put:
|
||||
tags: [Callbacks]
|
||||
summary: Update callback subscription
|
||||
description: Updates callback subscription fields. The current handler requires `id`, `organizationRef`, and `url`; omitted mutable fields may be reset to defaults.
|
||||
operationId: callbacksUpdate
|
||||
security:
|
||||
- bearerAuth: []
|
||||
requestBody:
|
||||
$ref: ./bodies/callback.yaml#/components/requestBodies/CallbackUpdateBody
|
||||
responses:
|
||||
'200':
|
||||
description: Callback updated
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
allOf:
|
||||
- $ref: ../response/response.yaml#/components/schemas/BaseResponse
|
||||
- type: object
|
||||
properties:
|
||||
data:
|
||||
$ref: ./response/callback.yaml#/components/schemas/CallbacksAuthData
|
||||
'400':
|
||||
$ref: ../response/operation.yaml#/components/responses/BadRequest
|
||||
'401':
|
||||
$ref: ../response/operation.yaml#/components/responses/Unauthorized
|
||||
'403':
|
||||
$ref: ../response/operation.yaml#/components/responses/Forbidden
|
||||
'404':
|
||||
$ref: ../response/operation.yaml#/components/responses/NotFound
|
||||
'500':
|
||||
$ref: ../response/operation.yaml#/components/responses/InternalServerError
|
||||
Reference in new issue
Block a user