VRChat.Prints (vrchat v1.20.0)

View Source

API calls for all endpoints tagged Prints.

Summary

Functions

Delete Print Returns a print.

Get Print Returns a print.

Get Own Prints Returns a list of all prints of the user. User id has to be your own userId, as you can't request other user's prints.

Upload Print Uploads and creates a print.

Functions

delete_print(connection, print_id, opts \\ [])

@spec delete_print(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, nil} | {:ok, VRChat.Model.Error.t()} | {:error, Tesla.Env.t()}

Delete Print Returns a print.

Parameters

  • connection (VRChat.Connection): Connection to server
  • print_id (String.t): Print ID.
  • opts (keyword): Optional parameters

Returns

  • {:ok, nil} on success
  • {:error, Tesla.Env.t} on failure

edit_print(connection, print_id, image, opts \\ [])

@spec edit_print(Tesla.Env.client(), String.t(), String.t(), keyword()) ::
  {:ok, VRChat.Model.Print.t()}
  | {:ok, VRChat.Model.Error.t()}
  | {:error, Tesla.Env.t()}

Edit Print Edits a print.

Parameters

  • connection (VRChat.Connection): Connection to server
  • print_id (String.t): Print ID.
  • image (String.t): The binary blob of the png file.
  • opts (keyword): Optional parameters
    • :note (String.t): The caption for the image.

Returns

  • {:ok, VRChat.Model.Print.t} on success
  • {:error, Tesla.Env.t} on failure

get_print(connection, print_id, opts \\ [])

@spec get_print(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, VRChat.Model.Print.t()}
  | {:ok, VRChat.Model.Error.t()}
  | {:error, Tesla.Env.t()}

Get Print Returns a print.

Parameters

  • connection (VRChat.Connection): Connection to server
  • print_id (String.t): Print ID.
  • opts (keyword): Optional parameters

Returns

  • {:ok, VRChat.Model.Print.t} on success
  • {:error, Tesla.Env.t} on failure

get_user_prints(connection, user_id, opts \\ [])

@spec get_user_prints(Tesla.Env.client(), String.t(), keyword()) ::
  {:ok, VRChat.Model.Error.t()}
  | {:ok, [VRChat.Model.Print.t()]}
  | {:error, Tesla.Env.t()}

Get Own Prints Returns a list of all prints of the user. User id has to be your own userId, as you can't request other user's prints.

Parameters

  • connection (VRChat.Connection): Connection to server
  • user_id (String.t): Must be a valid user ID.
  • opts (keyword): Optional parameters

Returns

  • {:ok, [%Print{}, ...]} on success
  • {:error, Tesla.Env.t} on failure

upload_print(connection, image, timestamp, opts \\ [])

@spec upload_print(Tesla.Env.client(), String.t(), DateTime.t(), keyword()) ::
  {:ok, VRChat.Model.Print.t()}
  | {:ok, VRChat.Model.Error.t()}
  | {:error, Tesla.Env.t()}

Upload Print Uploads and creates a print.

Parameters

  • connection (VRChat.Connection): Connection to server
  • image (String.t): The binary blob of the png file.
  • timestamp (DateTime.t): The time the image was captured.
  • opts (keyword): Optional parameters
    • :note (String.t): The caption for the image.
    • :worldId (String.t): The id of the world in which the image was captured.
    • :worldName (String.t): The name of the world in which the image was captured.

Returns

  • {:ok, VRChat.Model.Print.t} on success
  • {:error, Tesla.Env.t} on failure