Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ public partial interface ISimliClient
/// <param name="camera">
/// The camera the video starts with, on top of the avatar's own framing. Trinity-2 only. Leave it out to keep the avatar's framing.
/// </param>
/// <param name="backgroundId">
/// One of your uploaded backgrounds, by the id POST /assets/backgrounds returned, to show behind the avatar, cropped to fill the canvas. Trinity-2 only. Leave it out for the avatar's own. An id that is not one of your account's is dropped with a warning, and the video uses the avatar's own. An image is not accepted: upload it first.
/// </param>
/// <param name="foregroundId">
/// One of your uploaded foregrounds, by the id POST /assets/foregrounds returned, laid over the avatar through its transparency and cropped to fill the canvas. Trinity-2 only; otherwise as background_id.
/// </param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::System.InvalidOperationException"></exception>
Expand All @@ -85,6 +91,8 @@ public partial interface ISimliClient
double? avatarPositionX = default,
double? avatarPositionY = default,
global::Simli.CameraSetting? camera = default,
global::System.Guid? backgroundId = default,
global::System.Guid? foregroundId = default,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#nullable enable

namespace Simli
{
public partial interface ISimliClient
{
/// <summary>
/// Delete a Background or Foreground<br/>
/// Deletes one of your uploaded backgrounds or foregrounds. This can not be undone. A token or agent that names it starts with the avatar's own instead.
/// </summary>
/// <param name="kind"></param>
/// <param name="id"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task DeleteAssetAssetsKindAssetIdDeleteAsync(
global::Simli.AssetKind kind,
global::System.Guid id,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
/// <summary>
/// Delete a Background or Foreground<br/>
/// Deletes one of your uploaded backgrounds or foregrounds. This can not be undone. A token or agent that names it starts with the avatar's own instead.
/// </summary>
/// <param name="kind"></param>
/// <param name="id"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.AutoSDKHttpResponse> DeleteAssetAssetsKindAssetIdDeleteAsResponseAsync(
global::Simli.AssetKind kind,
global::System.Guid id,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#nullable enable

namespace Simli
{
public partial interface ISimliClient
{
/// <summary>
/// List Backgrounds or Foregrounds<br/>
/// Your uploaded backgrounds or foregrounds, newest first, each with a signed URL that reads the image (a PNG) until url_expires_at, an hour on. Anyone holding the URL can read that one image until then, so keep it to your own app. List again for fresh URLs.
/// </summary>
/// <param name="kind"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::System.Collections.Generic.IList<global::Simli.ListedAsset>> ListAssetsAssetsKindGetAsync(
global::Simli.AssetKind kind,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
/// <summary>
/// List Backgrounds or Foregrounds<br/>
/// Your uploaded backgrounds or foregrounds, newest first, each with a signed URL that reads the image (a PNG) until url_expires_at, an hour on. Anyone holding the URL can read that one image until then, so keep it to your own app. List again for fresh URLs.
/// </summary>
/// <param name="kind"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.AutoSDKHttpResponse<global::System.Collections.Generic.IList<global::Simli.ListedAsset>>> ListAssetsAssetsKindGetAsResponseAsync(
global::Simli.AssetKind kind,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,12 @@ public partial interface ISimliClient
/// <param name="camera">
/// The camera the session starts with, on top of the avatar's own framing. Trinity-2 only. Leave it out to keep the avatar's framing. A streaming session can move it afterwards with CAM_ messages.
/// </param>
/// <param name="backgroundId">
/// One of your uploaded backgrounds, by the id POST /assets/backgrounds returned, to show behind the avatar, cropped to fill the canvas. Trinity-2 only. Leave it out for the avatar's own. An id that is not one of your account's is dropped with a warning, and the session uses the avatar's own. An image is not accepted: upload it first. A streaming session can change it afterwards with BG_ messages.
/// </param>
/// <param name="foregroundId">
/// One of your uploaded foregrounds, by the id POST /assets/foregrounds returned, laid over the avatar through its transparency and cropped to fill the canvas. Trinity-2 only; otherwise as background_id. A streaming session can change it afterwards with FG_ messages.
/// </param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::System.InvalidOperationException"></exception>
Expand All @@ -90,6 +96,8 @@ public partial interface ISimliClient
double? avatarPositionX = default,
double? avatarPositionY = default,
global::Simli.CameraSetting? camera = default,
global::System.Guid? backgroundId = default,
global::System.Guid? foregroundId = default,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
#nullable enable

namespace Simli
{
public partial interface ISimliClient
{
/// <summary>
/// Upload Background or Foreground<br/>
/// Uploads an image to show behind your avatars (a background) or over them (a foreground). It goes through a content safety check first, which takes a few seconds, and one it flags is refused. Stored as PNG, private to your account: only your own sessions can use it, by its id, as a session token's, a static video's or an Auto session's background_id / foreground_id, or in a streaming session's BG_ / FG_ message.
/// </summary>
/// <param name="kind"></param>
/// <param name="request"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.Asset> UploadAssetAssetsKindPostAsync(
global::Simli.AssetKind kind,

global::Simli.BodyUploadAssetAssetsKindPost request,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
/// <summary>
/// Upload Background or Foreground<br/>
/// Uploads an image to show behind your avatars (a background) or over them (a foreground). It goes through a content safety check first, which takes a few seconds, and one it flags is refused. Stored as PNG, private to your account: only your own sessions can use it, by its id, as a session token's, a static video's or an Auto session's background_id / foreground_id, or in a streaming session's BG_ / FG_ message.
/// </summary>
/// <param name="kind"></param>
/// <param name="request"></param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.AutoSDKHttpResponse<global::Simli.Asset>> UploadAssetAssetsKindPostAsResponseAsync(
global::Simli.AssetKind kind,

global::Simli.BodyUploadAssetAssetsKindPost request,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
/// <summary>
/// Upload Background or Foreground<br/>
/// Uploads an image to show behind your avatars (a background) or over them (a foreground). It goes through a content safety check first, which takes a few seconds, and one it flags is refused. Stored as PNG, private to your account: only your own sessions can use it, by its id, as a session token's, a static video's or an Auto session's background_id / foreground_id, or in a streaming session's BG_ / FG_ message.
/// </summary>
/// <param name="kind"></param>
/// <param name="image">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="imagename">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::System.InvalidOperationException"></exception>
global::System.Threading.Tasks.Task<global::Simli.Asset> UploadAssetAssetsKindPostAsync(
global::Simli.AssetKind kind,
byte[] image,
string imagename,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);

/// <summary>
/// Upload Background or Foreground<br/>
/// Uploads an image to show behind your avatars (a background) or over them (a foreground). It goes through a content safety check first, which takes a few seconds, and one it flags is refused. Stored as PNG, private to your account: only your own sessions can use it, by its id, as a session token's, a static video's or an Auto session's background_id / foreground_id, or in a streaming session's BG_ / FG_ message.
/// </summary>
/// <param name="kind"></param>
/// <param name="image">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="imagename">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.Asset> UploadAssetAssetsKindPostAsync(
global::Simli.AssetKind kind,
global::System.IO.Stream image,
string imagename,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
/// <summary>
/// Upload Background or Foreground<br/>
/// Uploads an image to show behind your avatars (a background) or over them (a foreground). It goes through a content safety check first, which takes a few seconds, and one it flags is refused. Stored as PNG, private to your account: only your own sessions can use it, by its id, as a session token's, a static video's or an Auto session's background_id / foreground_id, or in a streaming session's BG_ / FG_ message.
/// </summary>
/// <param name="kind"></param>
/// <param name="image">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="imagename">
/// JPEG, PNG or WEBP, under 5MB, in one of the streaming canvases' shapes: 16:9, 9:16 or 1:1 and no other, at least 512 pixels on its shorter side and at most 1920x1080, 1080x1920 or 1080x1080. A foreground needs transparency (a PNG or WEBP with an alpha channel). EXIF orientation is applied; metadata is dropped.
/// </param>
/// <param name="requestOptions">Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.</param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::Simli.ApiException"></exception>
global::System.Threading.Tasks.Task<global::Simli.AutoSDKHttpResponse<global::Simli.Asset>> UploadAssetAssetsKindPostAsResponseAsync(
global::Simli.AssetKind kind,
global::System.IO.Stream image,
string imagename,
global::Simli.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
}
53 changes: 53 additions & 0 deletions src/libs/Simli/Generated/Simli.JsonConverters.AssetKind.g.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#nullable enable

namespace Simli.JsonConverters
{
/// <inheritdoc />
public sealed class AssetKindJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Simli.AssetKind>
{
/// <inheritdoc />
public override global::Simli.AssetKind Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Simli.AssetKindExtensions.ToEnum(stringValue) ?? default;
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Simli.AssetKind)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Simli.AssetKind);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Simli.AssetKind value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

writer.WriteStringValue(global::Simli.AssetKindExtensions.ToValueString(value));
}
}
}
Loading
Loading