-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feature(graphql): add create tenant admin api (#2921)
* refactor(backend): update rate caching (#2891) * chore(localenv): fix startup migration (#2897) * feat(backend): add trace to outgoing payment lifecycle (#2884) * feat(backend): add trace to outgoing payment lifecycle * feat(backend): encapsulate query lookup in trace * chore(localenv): remove traces from default localenv --------- Co-authored-by: Max Kurapov <max@interledger.org> * Add migration files * Update migration files * Fix file name for migrations * feat(tenant): basic tenant admin api schema and service * Remove cascade deletion * feat(auth): create basic tenant service and model plus graphql schema * feat(graphql): generated data * feat(graphql): add create tenant resolver and call service and update graphql schema * feat(auth): add basic tenant schema and appropriate resources like model and service * feat(generated): graphql schema * feat(auth): add tenant id to create tenant input * feat(auth): rename tenant id and add basic logic for calling create tenant service * feat(auth): add basic create tenant functionality in service * Add tenant model in backend * feat(backend): add apollo client do dependencies * feat(auth): add delete tenant mutation to the schema * feat(auth): delete tenant * Add tenantId field on resources models, update migration * chore(auth): format * feat(backend): create tenant service implementation * feat(auth): codegen for putting generated files to backend * feat(packages): make multi tenant work wip * feat(mock-lib): add tenants to the seeding step * feat(backend): update resolvers with tenant id and finish the tenant creation * feat(localenv): update seed and docker compose * feat(generated): graphql schema * feat(bruno): admin auth create tenant mutation * feat(backend): small changes to schema + mapping of tenant to graphql + bruno * feat(everything): move endpoints to separate service, update bruno and schema do pagination and stuff --------- Co-authored-by: Max Kurapov <max@interledger.org> Co-authored-by: Nathan Lie <lie4nathan@gmail.com> Co-authored-by: bsanduc <bogdan.sandu@breakpointit.eu>
- Loading branch information
1 parent
f15f6de
commit 4a3b3c9
Showing
69 changed files
with
3,782 additions
and
127 deletions.
There are no files selected for viewing
40 changes: 40 additions & 0 deletions
40
bruno/collections/Rafiki/Rafiki Admin APIs/Create Tenant.bru
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
meta { | ||
name: Create Tenant | ||
type: graphql | ||
seq: 50 | ||
} | ||
|
||
post { | ||
url: {{RafikiGraphqlHost}}/graphql | ||
body: graphql | ||
auth: none | ||
} | ||
|
||
body:graphql { | ||
mutation CreateTenant($input: CreateTenantInput!) { | ||
createTenant(input: $input) { | ||
tenant { | ||
id | ||
} | ||
} | ||
} | ||
} | ||
|
||
body:graphql:vars { | ||
{ | ||
"input": { | ||
"idpConsentEndpoint": "https://interledger.org/consent", | ||
"idpSecret": "myVerySecureSecret", | ||
"endpoints": [ | ||
{ | ||
"type": "RatesUrl", | ||
"value": "https://interledger.org/rates" | ||
}, | ||
{ | ||
"type": "WebhookBaseUrl", | ||
"value": "https://interledger.org/webhooks" | ||
} | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
meta { | ||
name: Get Tenant | ||
type: graphql | ||
seq: 51 | ||
} | ||
|
||
post { | ||
url: {{RafikiGraphqlHost}}/graphql | ||
body: graphql | ||
auth: none | ||
} | ||
|
||
body:graphql { | ||
query GetTenant($id: ID!) { | ||
tenant(id:$id) { | ||
id | ||
kratosIdentityId | ||
createdAt | ||
updatedAt | ||
endpoints { | ||
pageInfo { | ||
startCursor | ||
endCursor | ||
hasNextPage | ||
hasPreviousPage | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
body:graphql:vars { | ||
{ | ||
"id": "7a0c75bd-6c09-4d38-b013-af89ab91557a" | ||
} | ||
} |
11 changes: 11 additions & 0 deletions
11
bruno/collections/Rafiki/Rafiki Admin APIs/Get Tenants.bru
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
meta { | ||
name: Get Tenants | ||
type: graphql | ||
seq: 52 | ||
} | ||
|
||
post { | ||
url: {{RafikiGraphqlHost}}/graphql | ||
body: none | ||
auth: none | ||
} |
11 changes: 11 additions & 0 deletions
11
bruno/collections/Rafiki/Rafiki Admin Auth APIs/Create Tenant.bru
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
meta { | ||
name: Create Tenant | ||
type: graphql | ||
seq: 4 | ||
} | ||
|
||
post { | ||
url: {{RafikiAuthGraphqlHost}}/graphql | ||
body: none | ||
auth: none | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.