Skip to content

Share CLI command - node

share node

Manage Uni nodes.

Table of Contents

Commands

Manage nodes in a Uni

Usage

Terminal window
share node <subcommand>
Sub commanddescription
node add-api-keyAdd an API Key
node add-jwt-authAdd a custom JWT Authentication Provider to a Node
node getGet node configuration
node grant-accessGrant user access to a Node
node remove-jwt-authRemove a custom JWT Authentication Provider from a Node
node revoke-accessRevoke a user’s access to a Node
node schemaFetch a Node’s GraphQL Schema
node sharing-policyManage sharing policies for a node
node updateUpdate node configuration

Examples

Terminal window
Get Node info
share node get --uni <uniName>
share node get --uni <uniName> --node <nodeName>
share node get --uni <uniName> --node <nodeName> --json | jq '.'
Update node settings
share node update --uni <uniName> --node <nodeName> --config '{"blockReportEmails":["email@email.com"]}'
Get node GraphQL schema
share node schema --uni <uniName>
share node schema --uni <uniName> --node <nodeName>
Grant one or more users access to a Node
share node grant-access --uni <uniName> --node <nodeName> --user john@acme.com --user jill@acme.com --accessLevel ALL
Revoke one or more users' access to a Node
share node revoke-access --uni <uniName> --node <nodeName> --user john@acme.com --user jill@acme.com
❯ Add an API Key for a Node
share node add-api-key --uni <uniName> --node <nodeName> --name <name> --expiry <expiry>
❯ Add a JWT Authentication Provider
share node add-jwt-auth --uni <uniName> --node <nodeName> --name <name> --jwksUrl <jwksUrl> --issuer <issuer> --audience <audience> --scopes <scopes>
❯ Remove a JWT Authentication Provider
share node remove-jwt-auth --uni <uniName> --node <nodeName> --name <name>

node add-api-key

Add an API Key

Usage

Terminal window
share node add-api-key

Flags

  • uni (option) - The name of Uni
  • node (option) - The name of Node to modify
  • name (option) - The name of the API Key
  • expiry (option) - The expiration date of the API Key

Examples

Terminal window
share node add-api-key --uni <uniName> --node <nodeName> --name <name> --expiry <expiry>

node add-jwt-auth

Add a custom JWT Authentication Provider to a Node

Usage

Terminal window
share node add-jwt-auth

Flags

  • uni (option) - The name of Uni
  • node (option) - The name of Node to modify
  • name (option) - A unique resource name for this JWT (JSON Web Token) authentication.
  • jwksUrl (option) - The JSON Web Key Set (JWKS) is a set of keys containing the public keys used to verify any JSON Web Token (JWT) issued by the authorization server and signed using the RS256 signing algorithm.
  • issuer (option) - The ‘iss’ (issuer) claim identifies the principal that issued the JWT.
  • audience (option) - The ‘aud’ (audience) claim identifies the recipients that the JWT is intended for.
  • scopes (option) - The scopes required to access the API resource. Separated by spaces (eg. “read:product write:product ”).

Examples

Terminal window
share node add-jwt-auth --uni <uniName> --node <nodeName> --name <name> --jwksUrl <jwksUrl> --issuer <issuer> --audience <audience> --scopes <scopes>

node get

Get node configuration

Usage

Terminal window
share node get

Flags

  • uni (option) - Name of Uni
  • node (option) - Name of Node
  • json (boolean) - Output return values as JSON
  • role (option) - Role name to use for the operation

Examples

Terminal window
share node get --uni <uniName>
share node get --uni <uniName> --node <nodeName>
share node get --uni <uniName> --node <nodeName> --json | jq '.'

node grant-access

Grant user access to a Node

Usage

Terminal window
share node grant-access

Flags

  • uni (option) - The name of Uni
  • node (option) - The name of Node to modify
  • user (option) - E-mail address of the user to which to grant access
  • accessLevel (option) - Access level to grant user(s)

Examples

Terminal window
share node grant-access --uni <uniName> --node <nodeName> --user john@acme.com --user jill@acme.com --accessLevel ALL

node remove-jwt-auth

Remove a custom JWT Authentication Provider from a Node

Usage

Terminal window
share node remove-jwt-auth

Flags

  • uni (option) - The name of Uni
  • node (option) - The name of Node to modify
  • name (option) - A unique resource name for this JWT (JSON Web Token) authentication.

Examples

Terminal window
share node remove-jwt-auth --uni <uniName> --node <nodeName> --name <name>

node revoke-access

Revoke a user’s access to a Node

Usage

Terminal window
share node revoke-access

Flags

  • uni (option) - The name of Uni
  • node (option) - The name of Node to modify
  • user (option) - E-mail address of the user to which to revoke access

Examples

Terminal window
share node revoke-access --uni <uniName> --node <nodeName> --user john@acme.com --user jill@acme.com

node schema

Fetch a Node’s GraphQL Schema

Usage

Terminal window
share node schema

Flags

  • uni (option) - Name of Uni
  • node (option) - Name of Node
  • json (boolean) - Output return values as JSON

Examples

Terminal window
share node schema --uni <uniName>
share node schema --uni <uniName> --node <nodeName>

node sharing-policy

Manage sharing policies for a node

See https://docs.vendia.com/fine-grained-data-permissions

Usage

Terminal window
share auth sharing-policy <SubCommand>

Examples

Terminal window
Add a sharing policy
share node sharing-policy add --uni <uniName> --node <nodeName> --name test-policy --entity Product --acl '[]' --description 'test policy for sharing products'

node update

Update node configuration

Usage

Terminal window
share node update

Flags

  • uni (option) - Name of Uni
  • node (option) - Name of Node
  • config (option) - config values to set
  • force (boolean) - Force config update & ignore prompts
  • json (boolean) - Output return values as JSON

Examples

Terminal window
share node update --uni <uniName> --node <nodeName> --config '{"blockReportEmails":["email@email.com"]}'