Skip to content

Commit

Permalink
feat: add client queries
Browse files Browse the repository at this point in the history
  • Loading branch information
rohan-chaturvedi committed Oct 21, 2024
1 parent 5da23ce commit 619a191
Show file tree
Hide file tree
Showing 4 changed files with 51 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
mutation CreateServiceAccount(
$name: String!
$orgId: ID!
$roleId: ID!
$identityKey: String!
$handlers: [ServiceAccountHandlerInput]
$serverWrappedKeyring: String
$serverWrappedRecovery: String
) {
createServiceAccount(
name: $name
organisationId: $orgId
roleId: $roleId
identityKey: $identityKey
handlers: $handlers
serverWrappedKeyring: $serverWrappedKeyring
serverWrappedRecovery: $serverWrappedRecovery
) {
serviceAccount {
id
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
mutation DeleteServiceAccount($id: ID!) {
deleteServiceAccount(serviceAccountId: $id) {
ok
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
query GetServiceAccountHandlers($orgId: ID!) {
serviceAccountHandlers(orgId: $orgId) {
id
role {
name
permissions
}
identityKey
self
}
}
12 changes: 12 additions & 0 deletions frontend/graphql/queries/service-accounts/getServiceAccounts.gql
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
query GetServiceAccounts($orgId: ID!) {
serviceAccounts(orgId: $orgId) {
id
name
role {
id
name
permissions
}
createdAt
}
}

0 comments on commit 619a191

Please sign in to comment.