Skip to content

5 ‐ API Reference ‐ Stack Operations

Major edited this page Feb 25, 2026 · 1 revision

Purpose

Reference for stack, album, and related API operations exposed through the client layer.

Client Behavior

  • Request timeout around long-running asset fetches.
  • Retry with short exponential backoff for transient failures.
  • Optional dry-run no-op for write operations.

Core Stack Operations

  • FetchAllStacks()
  • ModifyStack(assetIDs []string)
  • DeleteStack(stackID string, reason string)

Related Asset Operations

  • FetchAssets(size int, stacksMap map[string]utils.TStack)
  • ListDuplicates(allAssets []utils.TAsset)
  • FetchTrashedAssets(size int)
  • TrashAssets(assetIDs []string)

Album Operations

  • FetchAlbums()
  • FetchAlbumAssets(albumID string)
  • CreateAlbum(name, description string)
  • AddAssetsToAlbum(albumID string, assetIDs []string)

How It Works

  • Existing state is fetched first.
  • Desired stack groups are computed.
  • Client applies minimum required mutations.

Example

stacks, err := client.FetchAllStacks()
if err != nil {
    return err
}
_ = stacks

Clone this wiki locally