Nuon.Api.Orgs (nuon v0.19.90)

API calls for all endpoints tagged Orgs.

Summary

Functions

Get an org's health checks Fetch the most recent health checks for an org. Health checks are automatically performed once every 60 seconds.

Return current user's orgs

Functions

Link to this function

add_user(connection, service_create_org_user_request, opts \\ [])

Add a user to the current org

Parameters

  • connection (Nuon.Connection): Connection to server
  • service_create_org_user_request (ServiceCreateOrgUserRequest): Input
  • opts (keyword): Optional parameters

Returns

  • {:ok, Nuon.Model.AppUserOrg.t} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

create_org(connection, service_create_org_request, opts \\ [])

create a new org

Parameters

  • connection (Nuon.Connection): Connection to server
  • service_create_org_request (ServiceCreateOrgRequest): Input
  • opts (keyword): Optional parameters

Returns

  • {:ok, Nuon.Model.AppOrg.t} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

delete_org(connection, opts \\ [])

@spec delete_org(
  Tesla.Env.client(),
  keyword()
) ::
  {:ok, Nuon.Model.StderrErrResponse.t()}
  | {:ok, boolean()}
  | {:error, Tesla.Env.t()}

Delete an org

Parameters

  • connection (Nuon.Connection): Connection to server
  • opts (keyword): Optional parameters

Returns

  • {:ok, boolean()} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

get_org(connection, opts \\ [])

@spec get_org(
  Tesla.Env.client(),
  keyword()
) ::
  {:ok, Nuon.Model.AppOrg.t()}
  | {:ok, Nuon.Model.StderrErrResponse.t()}
  | {:error, Tesla.Env.t()}

Get an org

Parameters

  • connection (Nuon.Connection): Connection to server
  • opts (keyword): Optional parameters

Returns

  • {:ok, Nuon.Model.AppOrg.t} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

get_org_health_checks(connection, opts \\ [])

@spec get_org_health_checks(
  Tesla.Env.client(),
  keyword()
) ::
  {:ok, Nuon.Model.StderrErrResponse.t()}
  | {:ok, [Nuon.Model.AppOrgHealthCheck.t()]}
  | {:error, Tesla.Env.t()}

Get an org's health checks Fetch the most recent health checks for an org. Health checks are automatically performed once every 60 seconds.

Parameters

  • connection (Nuon.Connection): Connection to server
  • opts (keyword): Optional parameters
    • :limit (integer()): limit of health checks to return

Returns

  • {:ok, [%AppOrgHealthCheck{}, ...]} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

get_orgs(connection, opts \\ [])

@spec get_orgs(
  Tesla.Env.client(),
  keyword()
) ::
  {:ok, Nuon.Model.StderrErrResponse.t()}
  | {:ok, [Nuon.Model.AppOrg.t()]}
  | {:error, Tesla.Env.t()}

Return current user's orgs

Parameters

  • connection (Nuon.Connection): Connection to server
  • opts (keyword): Optional parameters

Returns

  • {:ok, [%AppOrg{}, ...]} on success
  • {:error, Tesla.Env.t} on failure
Link to this function

update_org(connection, service_update_org_request, opts \\ [])

Update current org

Parameters

  • connection (Nuon.Connection): Connection to server
  • service_update_org_request (ServiceUpdateOrgRequest): Input
  • opts (keyword): Optional parameters

Returns

  • {:ok, Nuon.Model.AppOrg.t} on success
  • {:error, Tesla.Env.t} on failure