Skip to main content
POST
Reuse an existing source without the full wizard
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Description

POST /source-creator/reuse Description: Links an existing RoyaltySource to the current tenant by creating a TenantDataSource row directly — skips the wizard entirely. The source must be public: true and isActive: true, or already linked to the calling tenant. Returns 200 with alreadyLinked: true if the link already exists (idempotent), 201 otherwise. Triggers a v_sales_data rebuild after linking. Authorization:
  • Required role: admin or higher
Method: POST

Code Examples

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Body

application/json
royaltySourceId
string<uuid>
required

Response

Source already linked to tenant

status
string
Example:

"success"

message
string
Example:

"Source already linked to tenant"

data
object