LogoLogo
HomeSupportCommunity
  • Introduction
    • Overview
    • Get Started
      • Platforms & Packages
      • Use Cases
    • Glossary of Terms
  • Software
    • Bluetooth Wifi Onboarding Package (r3onboard)
    • Device Package
      • Supported Platforms
      • Installation
      • Usage
    • NPM Package
    • CLI
      • Supported Platforms
      • Installation
    • Docker
      • Remote.It Agent
      • Remote.it Docker Extension
    • Desktop
      • Installation
    • Web Portal & Mobile
    • Custom Solutions
  • Features
    • Services
      • SSH
      • RDP and VNC
      • SMB and CIFS
      • HTTP/S
      • Database
      • Redis
      • UDP
      • Gaming
      • VPN
    • Connection Options
      • LAN Sharing
      • Jump Service
      • Peer-2-Peer & Proxy
    • Logging
    • Organizations
  • Developer Tools
    • Authentication
    • API
      • Using Developer Tools
      • Usage
        • Devices and Services
        • Event Logs
        • Connections
        • Access Keys
        • Device Sharing
        • Custom Attributes
        • Scripting
    • CLI Usage
    • Webhooks
      • Slack Integration
    • Docker
    • Device Scripting
    • Zero-Trust AWS Access
      • AWS RDS (Postgres and MySQL)
    • Zero Trust Azure Cloud Access
    • Zero Trust Google Cloud Access
  • OEM & Bulk Provisioning
    • Overview
    • Auto Registration into Your Account
      • Create a Product
      • Production Image
      • Field Production
    • Registration into a User's Account
Powered by GitBook
On this page
  • Add or Remove
  • Leave

Was this helpful?

  1. Developer Tools
  2. API
  3. Usage

Device Sharing

PreviousAccess KeysNextCustom Attributes

Last updated 3 years ago

Was this helpful?

This mutation allows you to add or remove device and service sharing from your account to other users. DeviceId and ServiceId can be retrieved .

Parameters
Data Type
Description

deviceId

String

required

The ID of the device to share

email

[String]

required

The email(s) of the user you want to share the device with, or you can specify an array of emails.

scripting

Boolean

Grants bulk scripting permission to the user (default: false)

notify

Boolean

The user will be notified (default: true)

action

String

ADD, REMOVE, LEAVE (default: ADD)

services

[ServiceSharingOptions]

For sharing only a subset of services. This field and below is not required if sharing all services of a device

serviceId

String

The ID of the specific service associated with the deviceID

Add or Remove

This example shares and notifies email@example.com that deviceId 80:00:00:00:12:34:56:78 has been shared and all services associated with it but does not grant bulk scripting permissions.

mutation {
  share(deviceId: "80:00:00:00:12:34:56:78", 
        email: "email@example.com", 
        scripting: false,
        notify: true,
        action: ADD)
}

This example shares a service and removes a share of another service on the same device to multiple users.

mutation {
  share(deviceId: "80:00:00:00:12:34:56:78",
        email: [
          "email1@example.com",
          "email2@example.com"
        ],
        notify: true,
        services: [
          {serviceId: "80:00:00:00:12:34:56:79", action: ADD},
          {serviceId: "80:00:00:00:12:34:56:79", action: REMOVE}
        ]

Leave

If you want to leave a shared device that another user has shared with you previously

mutation {
  share(
    deviceId: "80:00:00:00:12:34:56:78"
    email: "YourEmail@example.com"
    action: LEAVE
  )
}

Response Example

{
  "data": {
    "share": true
  }
}
here