OBJECT
Mutation
link GraphQL Schema definition
- type Mutation {
- # Update your account details
- #
- # Arguments
- # email: Email address
- # companyName:
- # firstName:
- # lastName:
- # address:
- # postalCode:
- # city:
- # state:
- # country:
- # phone:
- # triton_cns_enabled: Enable or disable the Triton CNS
- (
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- Boolean :
- ): User
- # Uploads a new OpenSSH key to Triton for use in HTTP signing and SSH.
- #
- # Arguments
- # user: User id. Use this for sub-user keys
- # name: Name for this key
- # key: OpenSSH formatted public key
- ID, : String, : String!): Key ( :
- # Deletes a single SSH key, by name or fingerprint
- #
- # Arguments
- # user: User id. Use this for sub-user keys
- # name: Name for this key
- # fingerprint: OpenSSH formatted public key
- ID, : String, : String): Key ( :
- # Creates a new user under an account
- #
- # Arguments
- # email: Email address
- # login: Username
- # password: Password
- # companyName:
- # firstName:
- # lastName:
- # address:
- # postalCode:
- # city:
- # state:
- # country:
- # phone:
- (
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String :
- ): User
- # Update a user's modifiable properties
- #
- # Arguments
- # id:
- # login:
- # email:
- # companyName:
- # firstName:
- # lastName:
- # address:
- # postalCode:
- # city:
- # state:
- # country:
- # phone:
- (
- ID!, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String :
- ): User
- # This is a separate rule for password changes, so different policies can be used
- # for an user trying to modify other data, or only their own password
- #
- # Arguments
- # id:
- # password:
- # password_confirmation:
- (
- ID!, :
- String, :
- String :
- ): User
- # Remove a user
- #
- # Arguments
- # id:
- ID!): User ( :
- # Create a new role for your account
- #
- # Arguments
- # name: The role's name
- # policies: This account's policies to be given to this role
- # members: This account's user logins to be added to this role
- # default_members: This account's user logins to be added to this
- # role and have it enabled by default
- (
- String, :
- ID], : [
- ID], : [
- ID] : [
- ): Role
- # Modifies an account role. Anything but id can be modified
- #
- # Arguments
- # id: Role id
- # name: The role's name
- # policies: This account's policies to be given to this role
- # members: This account's user logins to be added to this role
- # default_members: This account's user logins to be added to this
- # role and have it enabled by default
- (
- ID!, :
- String, :
- ID], : [
- ID], : [
- ID] : [
- ): Role
- # Remove a role
- #
- # Arguments
- # id: Role id
- ID!): Role ( :
- # Creates a new account policy
- #
- # Arguments
- # name: The policy name
- # rules: One or more Aperture sentences to be added to the
- # current policy
- # description: A description for this policy
- String, : [String]!, : String): Policy ( :
- # Upgrades an existing account policy. Everything but id can be modified.
- #
- # Arguments
- # id: Policy id
- # name: The policy name
- # rules: One or more Aperture sentences to be added to the
- # current policy
- # description: A description for this policy
- ID!, : String, : [String], : String): Policy ( :
- # Delete an RBAC policy
- #
- # Arguments
- # id: Policy id
- ID!): Policy ( :
- # Updates configuration values for your account
- #
- # Arguments
- # default_network: ID of the network used for provisioning docker
- # containers
- String): [KeyValue] ( :
- # Delete an image. Caller must be the owner of the image to delete it
- #
- # Arguments
- # id: Image id
- ID): Image ( :
- # Exports an image to the specified Manta path. Caller must be the owner of the
- # image, and the correspondent Manta path prefix, in order to export it
- #
- #
- # Arguments
- #
- # id:
- #
- # Arguments
- # id: Image id
- # manta_path: Manta path prefix used when exporting the image
- ID, : String!): MantaLocation ( :
- # Create a new custom image from an instance
- #
- # Arguments
- # machine: The prepared and stopped instance UUID from which the
- # image is to be created
- # name: The name of the custom image, e.g. "my-image"
- # version: The version of the custom image, e.g. "1.0.0"
- # description: The image description
- # homepage: The image homepage
- # eula: The image eula
- # acl: The image acl
- # tags: The image tags
- (
- ID!, :
- String!, :
- String!, :
- String, :
- String, :
- String, :
- String, :
- KeyValueInput] : [
- ): Image
- # Create a new custom image from an instance
- #
- # Arguments
- # id: Image id
- # name: The name of the custom image, e.g. "my-image"
- # version: The version of the custom image, e.g. "1.0.0"
- # description: The image description
- # homepage: The image homepage
- # eula: The image eula
- # acl: The image acl
- # tags: The image tags
- (
- ID!, :
- String, :
- String, :
- String, :
- String, :
- String, :
- String, :
- KeyValueInput] : [
- ): Image
- # Allows you to provision an instance.
- #
- #
- # If you do not specify a name, CloudAPI will generate a random one for you. If
- # you have enabled Triton CNS on your account, this name will also be used in DNS
- # to refer to the new instance (and must therefore consist of DNS-safe characters
- # only).
- #
- #
- # Your instance will initially be not available for login (Triton must provision
- # and boot it); you can poll
- # [GetMachine](https://apidocs.joyent.com/cloudapi/#GetMachine) for its status.
- # When the `state` field is equal to `running`, you can log in. If the instance is
- # a `brand` other than `kvm`, you can usually use any of the SSH keys managed
- # under the [keys section](https://apidocs.joyent.com/cloudapi/#keys) of CloudAPI
- # to login as any POSIX user on the OS. You can add/remove keys over time, and the
- # instance will automatically work with that set.
- #
- #
- # If the the instance has a brand `kvm`, and of a UNIX-derived OS (e.g. Linux),
- # you must have keys uploaded before provisioning; that entire set of keys will be
- # written out to `/root/.ssh/authorized_keys` in the new instance, and you can SSH
- # in using one of those keys. Changing the keys over time under your account will
- # not affect a running hardware virtual machine in any way; those keys are
- # statically written at provisioning-time only, and you will need to manually
- # manage them on the instance itself.
- #
- #
- # If the image you create an instance from is set to generate passwords for you,
- # the username/password pairs will be returned in the metadata response as a
- # nested object, like so:
- #
- #
- # ```json
- #
- # "metadata": {
- #
- # "credentials": {
- #
- # "root": "s8v9kuht5e",
- #
- # "admin": "mf4bteqhpy"
- #
- # }
- #
- # }
- #
- # ```
- #
- #
- # You cannot overwrite the `credentials` key in CloudAPI.
- #
- #
- # More generally, the metadata keys can be set either at the time of instance
- # creation, or after the fact. You must either pass in plain-string values, or a
- # JSON-encoded string. On metadata retrieval, you will get a JSON object back.
- #
- #
- # Networks can be specified using the networks attribute. If it is absent from the
- # input, the instance will default to attaching to one externally-accessible
- # network (it will have one public IP), and one internally-accessible network from
- # the datacenter network pools. It is possible to have an instance attached to
- # only an internal network, or both public and internal, or just external.
- #
- #
- # Be aware that CreateMachine does not return IP addresses or networks. To obtain
- # the IP addresses and networks of a newly-provisioned instance, poll
- # [GetMachine](https://apidocs.joyent.com/cloudapi/#GetMachine) until the instance
- # state is `running`.
- #
- #
- # Typically, Triton will allocate the new instance somewhere reasonable within the
- # cloud. See [affinity rules](https://apidocs.joyent.com/cloudapi/#affinity-rules)
- # below for options on controlling server placement of new instances.
- #
- #
- # When Triton CNS is enabled, the DNS search domain of the new VM will be
- # automatically set to the suffix of the "instance" record that is created for
- # that VM. For example, if the full CNS name of the new VM would be
- # "foo.inst.35ad1ec4-2eab-11e6-ac02-8f56c66976a1.us-west-1.triton.zone", its
- # automatic DNS search path would include
- # "inst.35ad1ec4-2eab-11e6-ac02-8f56c66976a1.us-west-1.triton.zone". This can be
- # changed later within the instance, if desired.
- #
- # Arguments
- # name: Friendly name for this instance; default is the first 8
- # characters of the machine id. If the name includes the string {{shortId}}, any
- # instances of that tag within the name will be replaced by the first 8 characters
- # of the machine id.
- # package: Id of the package to use on provisioning, obtained
- # from ListPackages
- # image: The image UUID
- # networks: Desired networks ids
- # affinity: Optional array of affinity rules
- # metadata: An arbitrary set of metadata key/value pairs can be
- # set at provision time, but they must be prefixed with "metadata"
- # tags: An arbitrary set of tags can be set at provision time,
- # but they must be prefixed with "tag"
- # firewall_enabled: Completely enable or disable firewall for
- # this instance. Default is false
- (
- String!, :
- ID!, :
- ID!, :
- ID], : [
- AffinityRule], : [
- KeyValueInput], : [
- KeyValueInput], : [
- Boolean :
- ): Machine
- # Allows you to shut down an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Allows you to boot up an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Allows you to reboot an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Resize an instance to a new package
- #
- #
- # Resizing is only supported for containers (instances which are not hardware
- # virtual machines -- they have brand=kvm). Hardware virtual machines cannot be
- # resized. Resizing is not guaranteed to work, especially when resizing upwards in
- # resources. It is best-effort, and may fail. Resizing downwards will usually
- # succeed.
- #
- # Arguments
- # id: Machine id
- # package: Package id
- ID!, : ID!): Machine ( :
- # Allows you to rename an instance
- #
- # Arguments
- # id: Machine id
- # name: Package id
- ID!, : String!): Machine ( :
- # Allows you to enable the firewall for an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Allows you to disable the firewall for an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Allows you to take a snapshot of an instance. Once you have one or more
- # snapshots, you can boot the instance from a previous snapshot. Snapshots are not
- # usable with other instances; they are a point-in-time snapshot of the current
- # instance. Snapshots can also only be taken of instances that are not of brand
- # 'kvm'.
- #
- # Arguments
- # id: Machine id
- # name:
- ID!, : String): Snapshot ( :
- # If an instance is in the 'stopped' state, you can choose to start the instance
- # from the referenced snapshot. This is effectively a means to roll back instance
- # state.
- #
- # Arguments
- # id: Machine id
- # snapshot:
- ID!, : ID!): Machine ( :
- # Deletes the specified snapshot of an instance
- #
- # Arguments
- # id: Machine id
- # snapshot:
- ID!, : ID!): Machine ( :
- # Allows you to update the metadata for a given instance. Note that updating the
- # metadata via CloudAPI will result in the metadata being updated in the running
- # instance. The semantics of this call are subtly different that the
- # AddMachineTags call -- any metadata keys passed in here are created if they do
- # not exist, and overwritten if they do.
- #
- # Arguments
- # id: Machine id
- # metadata: Metadata key value pairs
- ID!, : [KeyValueInput]): Machine ( :
- # Deletes a single metadata key from this instance
- #
- # Arguments
- # id: Machine id
- # name: Metadata key
- ID!, : String!): Machine ( :
- # Deletes all metadata keys from this instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Set tags on the given instance. A pre-existing tag with the same name as one
- # given will be overwritten
- #
- # Arguments
- # id: Machine id
- # tags: key value pairs
- ID!, : [KeyValueInput]!): Machine ( :
- # Fully replace all tags on an instance with the given tags
- #
- # Arguments
- # id: Machine id
- # tags: key value pairs
- ID!, : [KeyValueInput]!): Machine ( :
- # Deletes a single tag from this instance
- #
- # Arguments
- # id: Machine id
- # name: tag name
- ID!, : String!): Machine ( :
- # Deletes all tags from an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Allows you to completely destroy an instance
- #
- # Arguments
- # id: Machine id
- ID!): Machine ( :
- # Adds a new firewall rule for the specified account. This rule will be added to
- # all the account's instances where it may be necessary
- #
- # Arguments
- # enabled: Indicates if the rule is enabled (optional, false by
- # default)
- # rule: Firewall rule text
- # description: Human-readable description for the rule
- (
- Boolean, :
- String!, :
- String :
- ): FirewallRule
- # Adds a new firewall rule for the specified account. This rule will be added to
- # all the account's instances where it may be necessary
- #
- # Arguments
- # id: Firewall rule id
- # enabled: Indicates if the rule is enabled (false by default)
- # rule: Firewall rule text
- # description: Human-readable description for the rule
- (
- ID!, :
- Boolean, :
- String, :
- String :
- ): FirewallRule
- # Enables the given firewall rule if it is disabled
- #
- # Arguments
- # id: Firewall rule id
- ID!): FirewallRule ( :
- # Disables the given firewall rule if it is enabled
- #
- # Arguments
- # id: Firewall rule id
- ID!): FirewallRule ( :
- # Removes the given firewall rule from all the required instances
- #
- # Arguments
- # id: Firewall rule id
- ID!): FirewallRule ( :
- # Creates a new VLAN on the fabric
- #
- # Arguments
- # id: A number from 0-4095 that indicates the VLAN's id
- # name: A unique name to identify the VLAN
- # description: An optional description of the VLAN
- Int!, : String!, : String): VLAN ( :
- # Updates a fabric VLAN
- #
- # Arguments
- # id: The VLAN id
- # name: A unique name to identify the VLAN
- # description: An optional description of the VLAN
- Int!, : String, : String): VLAN ( :
- # Deletes the specified VLAN. Note there must be no networks on that VLAN in order
- # for the VLAN to be deleted.
- #
- # Arguments
- # id: The VLAN id
- Int!): VLAN ( :
- # Create Fabric network
- #
- # Arguments
- # vlan: The VLAN id
- # name: The network name; must be unique
- # description: Description of this network
- # subnet: A CIDR formatted string that describes the network
- # provision_start_ip: The first IP on the network that may be
- # assigned
- # provision_end_ip: The last IP on the network that may be
- # assigned
- # gateway: Gateway IP address
- # resolvers: Optional resolver IP addresses
- # routes: Optional Static routes for hosts on this network
- # internet_nat: Provision internet NAT zone on gateway address,
- # default is true
- (
- Int!, :
- String!, :
- String, :
- String!, :
- String, :
- String, :
- String, :
- String], : [
- KeyValueInput], : [
- Boolean :
- ): Network
- # Deletes the specified Network. Note that no instances may be provisioned on the
- # Network
- #
- # Arguments
- # vlan: The VLAN id
- # id: The network id
- Int!, : ID): Network ( :
- # Creates a new NIC on an instance belonging to a given account
- # *WARNING*: this causes the instance to reboot while adding the NIC
- #
- # Arguments
- # machine: Machine id
- # network: ID of network this NIC should attach to
- ID!, : ID!): NIC ( :
- # Removes a NIC on an instance belonging to a given account
- # *WARNING*: this causes the instance to reboot while removing the NIC
- #
- # Arguments
- # machine: Machine id
- # mac: NIC mac address
- ID, : String): NIC ( :
- }
link Require by
This element is not required by anyone