Skip to content

latitudesh/latitudesh-nodejs

Repository files navigation

@latitudesh/latitudesh-nodejs

Nodejs Package to use Latitude.sh API. Check our API documentation

Installation

npm install @latitudesh/latitudesh-nodejs

Usage

const latitudeSh = require('@latitudesh/latitudesh-nodejs');
latitudeShApi = new latitudeSh(<APITOKEN>);

// Async Await

const profile = (async () => {
  await latitudeShApi.Profile.get()
})

// Promise then

latitudeShApi.Profile.get().then((response) => {
  // success
}, (response) => {
  // failure
})

Available API Methods

  • ApiVersion.get Params: (). Reference

  • ApiVersion.list Params: (). Reference

  • ApiVersion.update Params: (bodyData). Reference

  • Account.Regions.list. Params: (searchParams). Deprecated

  • Billing.Usage.get Params: (searchParams). Reference

  • Ips.get. Params: (id, searchParams). Reference

  • Ips.list. Params: (searchParams). Reference

  • Plans.Bandwidth.list. Params: (). Reference

  • Plans.Bandwidth.update. Params: (bodyData). Reference

  • Plans.get. Params: (planId, searchParams). Reference

  • Plans.list. Params: (searchParams). Reference

  • Plans.operatingSystems. Params: (searchParams). Reference

  • Plans.storage. Params: (searchParams). Reference

  • Projects.Members.list. Params: (projectIdOrSlug, searchParams). Reference

  • Projects.SshKeys.create. Params: (projectIdOrSlug, bodyData). Reference

  • Projects.SshKeys.delete. Params: (projectIdOrSlug, sshKeyId). Reference

  • Projects.SshKeys.get. Params: (projectIdOrSlug, sshKeyId, searchParams). Reference

  • Projects.SshKeys.list. Params: (projectIdOrSlug, searchParams). Reference

  • Projects.SshKeys.update. Params: (projectIdOrSlug, sskKeyId, bodyData). Reference

  • Projects.UserData.create. Params: (projectIdOrSlug, bodyData). Reference

  • Projects.UserData.delete. Params: (projectIdOrSlug, userDataId). Reference

  • Projects.UserData.get. Params: (projectIdOrSlug, userDataId, searchParams). Reference

  • Projects.UserData.list. Params: (projectIdOrSlug, searchParams). Reference

  • Projects.UserData.update. Params: (projectIdOrSlug, userDataId, searchParams). Reference

  • Projects.create. Params: (bodyData). Reference

  • Projects.delete. Params: (projectIdOrSlug). Reference

  • Projects.get. Params: (projectIdOrSlug, searchParams). Reference

  • Projects.list. Params: (searchParams) Reference

  • Projects.update. Params: (projectIdOrSlug, bodyData). Reference

  • Regions.get. Params: (regionId, searchParams). Reference

  • Regions.list. Params: (searchParams) Reference

  • Server.Actions.getReinstall. Params: (serverId). Deprecated

  • Server.Actions.getRemoteAccess. Params: (serverId). Deprecated

  • Server.Actions.managePower. Params: (serverId, postData) Reference

  • Server.Actions.reinstall. Params: (serverId, bodyData). Reference

  • Server.Actions.scheduleDeletion. Params: (serverId). Reference

  • Server.Actions.unscheduleDeletion. Params: (serverId). Reference

  • Server.DeployConfig.get. Params: (serverId). Reference

  • Server.DeployConfig.update. Params: (serverId, bodyData). Reference

  • Server.Ips.list. Params: (serverId, searchParams). Deprecated

  • Server.RemoteAccess.create. Params: (serverId). Reference

  • Server.create. Params: (bodyData) Reference

  • Server.delete. Params: (deviceId, reason) Reference

  • Server.get. Params: (deviceId, searchParams) Reference

  • Server.list. Params: (searchParams) Reference

  • Server.update. Params: (deviceId, bodyData) Reference

  • Server.OutOfBand.create. Params: (serverId, bodyData) Reference

  • Server.OutOfBand.get. Params: (serverId) Reference

  • Server.RescueMode.enter. Params: (serverId) Reference

  • Server.RescueMode.exit. Params: (serverId). Reference

  • Teams.Members.create. Params: (bodyData). Reference

  • Teams.Members.delete. Params: (memberId). Reference

  • Teams.Members.list. Params: (searchParams). Reference

  • Teams.Tags.list. Params: (). Reference

  • Teams.Tags.create. Params: (bodyData). Reference

  • Teams.Tags.update. Params: (tagId, bodyData). Reference

  • Teams.Tags.delete. Params: (tagId). Reference

  • Teams.User.listTeams. Params: (searchParams). Reference

  • Teams.Roles.get. Params: (id). Reference

  • Teams.Roles.list. Params: (). Reference

  • Teams.create. Params: (bodyData). Reference

  • Teams.current. Params: (searchParams). Reference

  • Teams.update. Params: (teamId, data). Reference

  • Traffic.Quota.get. Params: (projectSlug). Reference

  • Traffic.get. Params: (searchParams). Reference

  • User.ApiKeys.create Params: (bodyData)`. Reference

  • User.ApiKeys.delete Params: (apiKeyId)`. Reference

  • User.ApiKeys.list Params: (searchParams)`. Reference

  • User.ApiKeys.update Params: (apiKeyId, bodyData)`. Reference

  • User.Profile.get Params: (searchParams)`. Reference

  • User.Profile.update Params: (userId, data)`. Reference

  • VirtualNetworks.Assignments.create. Params: (bodyData). Reference

  • VirtualNetworks.Assignments.delete. Params: (id). Reference

  • VirtualNetworks.Assignments.list. Params: (searchParams). Reference

  • VirtualNetworks.create. Params: (bodyData). Reference

  • VirtualNetworks.delete. Params: (id). Reference

  • VirtualNetworks.get. Params: (id, searchParams). Reference

  • VirtualNetworks.list. Params: (searchParams). Reference

  • VirtualNetworks.update. Params: (id, bodyData). Reference

  • VpnSessions.create. Params: (bodyData). Reference

  • VpnSessions.delete. Params: (sessionId). Reference

  • VpnSessions.list. Params: (searchParams). Reference

  • VpnSessions.refreshPassword. Params: (sessionId). Reference

  • Storage.create. Params: (bodyData). Reference

  • Storage.list. Params: (searchParams). Reference

  • Storage.update. Params: (fileSystemId, bodyData). Reference

  • Storage.delete. Params: (fileSystemId, queryParams). Reference

  • Firewall.get Params: (firewallId, searchParams). Reference

  • Firewall.list Params: (searchParams). Reference

  • Firewall.create Params: (bodyData). Reference

  • Firewall.update Params: (firewallId, bodyData). Reference

  • Firewall.getAssignments Params: (firewallId). Reference

  • Firewall.assign Params: (firewallId, bodyData). Reference

  • Firewall.unassign Params: (firewallId, assignmentId). Reference