GraphQL Schema Reference

Vendia Share API Schema

In addition to using the Vendia Share CLI, developers can also access all the same functionality directly through the Vendia Share API, a GraphQL-based HTTPS API with the URL https://share.services.vendia.net/share. A copy of the schema is documented below, but developers are encouraged to dynamically retrieve the schema through introspection queries to ensure its up to date.

Note that calls made to the Vendia Share API must be sigv4 signed with AWS credentials assigned to the Vendia user making the request.

Vendia Share GraphQL Schema Reference

enum CSPEnum {
  AWS
  AZURE
  GCP
  IBM
  ORACLE
  TENCENT
  ALICLOUD
}

enum StatusEnum {
  PENDING_REGISTRATION
  DEPLOYING
  RUNNING
  ADDING
  UPDATING
  ERROR
  UNKNOWN
  DESTROYING
  DESTROYED
  STOPPED
}

enum UniSkuEnum {
    SHARE,
    VDL
}

enum ActionEnum {
  ALL
  USER_ALL
  USER_GET
  USER_CREATE
  USER_DELETE
  USER_SET_EMAIL
  USER_SET_ROLE
  USER_DELETE_ROLE
  USER_INVITE
  GROUP_ALL
  GROUP_GET
  GROUP_CREATE
  GROUP_DELETE
  GROUP_ADD_USER
  GROUP_REMOVE_USER
  UNI_ALL
  UNI_CREATE
  UNI_DELETE
  UNI_RESET
  UNI_JOIN
  UNI_INVITE
  UNI_DELETE_NODE
  UNI_GET
  UNI_QUERY
  UNI_MUTATE
}

type Query {
  getUser(userId: String, role: String): User!
  getUni(uni: String!): Uni!
  getNode(uni: String!, node: String!): Node!
  listUnis(userId: String, limit: Int, nextToken: String, filter: StatusEnum): ListUnisConnection!
}

type Mutation {
  register(input: UniInput!, asRole: String): String!
  destroy(uni: String!, asRole: String): String!
  reset(uni: String!, logs: Boolean, asRole: String): String!
  invite(uni: String!, userId: String!, expiration: String, nodeLimit: Int, asRole: String): Invite!
  join(uni: String!, token: String!, input: NodeInput!, asRole: String): String
  createUser(userId: String!, asRole: String): User
  setUserEmail(userId: String, email: String!, asRole: String): String
  setUserRole(userId: String, roleName: String!, capabilities: [CapabilitiesInput!]!, asRole: String): String
  deleteUserRole(userId: String, roleName: String!, asRole: String): String
  deleteUser(userId: String, asRole: String): String
}

type User {
  userId: String!
  roles: [Role!]
  limits: [Limit!]
}

type Limit {
  name: String!
  value: Int!
}

type Account {
  csp: CSPEnum!
  accountId: String!
  org: String
}

type ListUnisConnection {
  unis: [Uni!]
  nextToken: String
  error: String
}

type ListUsersConnection {
  users: [User!]
  nextToken: String
  error: String
}

type Uni {
  name: String!
  sku: UniSkuEnum
  status: StatusEnum!
  nodes: [Node!]
  schema: String!
  initState: String
  created: String
  error: String
}

type Node {
  name: String!
  userId: String!
  description: String
  status: StatusEnum!
  region: String
  vendiaAccount: Account
  resources: NodeResources
}

type Invite {
  uni: String!
  userId: String!
  expiration: String
  token: String!
}

type NodeResources {
  graphqlApi: GraphqlApiInfo!
  aws_AsyncIngressQueue: AwsSqsInfo
  aws_FileStorage: AwsS3Info
  aws_BlockNotifications: AwsSnsInfo
  aws_Cognito: AwsCognitoInfo
}

type AwsCognitoInfo {
  userPoolId: String
  userPoolClientId: String
  identityPoolId: String
}

type AwsSqsInfo {
  url: String!
  name: String!
}

type AwsSnsInfo {
  arn: String!
  name: String!
}

type AwsS3Info {
  arn: String!
  name: String!
}

type GraphqlApiInfo {
  apiKey: String!
  httpsUrl: String!
  websocketUrl: String!
}

input UniInput {
  name: String!
  schema: String
  sku: UniSkuEnum
  initState: String
  nodes: [NodeInput!]!
}

input NodeInput {
  name: String!
  description: String
  userId: String!
  region: String
  settings: SettingsInput
}

type Capability {
  action: ActionEnum!
  resources: [String!]!
}

type Role {
  name: String!
  capabilities: [Capability!]!
}

input CapabilitiesInput {
  action: String!
  resources: [String!]!
}

input SettingsInput {
  blockReportWebhooks: [String!]
  blockReportEmails: [String!]
  deadLetterWebhooks: [String!]
  deadLetterEmails: [String!]
  aws_blockReportSQSQueues: [String!]
  aws_blockReportLambdas: [String!]
  aws_deadLetterSQSQueues: [String!]
  aws_deadLetterLambdas: [String!]
  aws_S3ReadAccounts: [String!]
  aws_SQSIngressAccounts: [String!]
  aws_LambdaIngressAccounts: [String!]
  apiSettings: APISettings
}

input APISettings {
  auth: APIAuth
  apiKeys: [APIKey!]
}

input APIAuth {
  authorizerType: String!
  authorizerArn: String
  allowedAccounts: [String!]
}

input APIKey {
  value: String!
  usagePlan: UsagePlan
}

input UsagePlan {
  quotaSettings: QuotaSettings
  throttleSettings: ThrottleSettings
}

input QuotaSettings {
  limit: Int!
  offset: Int!
  period: String!
}

input ThrottleSettings {
  burstLimit: Int!
  rateLimit: Int!
}