Skip to content

Releases: octaspace/go-sdk

v0.5.0 — Fix container_id decoding for compute sessions

Choose a tag to compare

@secretpray secretpray released this 22 Jul 19:42
9aed13c

Fixed

  • Session.ContainerID and SessionInfo.ContainerID now decode compute (MR)
    sessions correctly. The live API returns container_id as a JSON array for
    compute sessions (absent entirely for VPN sessions), but the field was typed
    as a bare string; any account with an active compute rental hit a decode
    error on the entire /sessions list and /services/:uuid/info, not just
    that one field. Verified against a live account with an active session.

Changed

  • Breaking: Session.ContainerID and SessionInfo.ContainerID are now
    FlexString instead of string. FlexString behaves like a normal string
    (.String(), comparable to string literals) but accepts both the legacy
    bare-string and the current array-of-strings shape, joining multiple
    container IDs with ", ". Callers holding these fields in an explicitly
    string-typed variable need .String() or an explicit conversion.

v0.4.0 — Correct node detail decoding (NodeDetail)

Choose a tag to compare

@secretpray secretpray released this 22 Jul 16:11
3470a3e

Fixed

  • NodesResource.Find now decodes the real GET /nodes/:id response. That
    endpoint uses a different JSON envelope than GET /nodes (system block nested
    under data, memory as total_memory/free_memory, agent version as
    data.version), so decoding it into Node silently zeroed CPU, RAM, disk,
    GPU, uptime, and agent-version fields. Verified against the live API (node 65).

Changed

  • Breaking: NodesResource.Find now returns *NodeDetail instead of
    *Node. NodeDetail faithfully models the detail envelope and adds
    reliability, account_id, and richer location/memory fields. Node prices
    are not part of this endpoint — use NodesResource.List for pricing.

v0.3.0 — Live API contract alignment

Choose a tag to compare

@secretpray secretpray released this 22 Jul 08:46

[0.3.0] - 2026-07-22

Added

  • MachineRentalResource.CreateSingle for the documented object-form
    machine-rental request, without changing the existing batch-array Create.
  • Scoped lossless JSON methods for apps, account profile, nodes, sessions,
    machine rentals, VPN relays, and per-session info.
  • Documentation guides under docs/ for setup, resources, machine rentals,
    sessions, raw JSON, reliability, and testing.

Fixed

  • App now retains start_command while decoding application templates.
  • SessionInfo models connection, lifecycle, pricing, hardware, and both
    config and vpn_config response keys.
  • Machine-rental prices in Wei, vendor-grouped GPUs, and reliability fields are
    retained by typed decoding.
  • Wallet-generation address, node memory usage, and live session account_id
    are retained by typed decoding.
  • Service-create results retain the presence-aware status field, including 0.
  • VPN relay decoding accepts both net_*_mbits and legacy net_*_mbs keys.

v0.2.0 — Render workers and live API alignment

Choose a tag to compare

@secretpray secretpray released this 21 Jul 19:13
e24e345

Added

  • client.Services.R for the distinct /services/r render-worker marketplace.
  • Typed multi-node worker requests and per-item create results.
  • Optional organization/project context for machine-rental creation.

Fixed

  • /services/mr now decodes the production per-item array response.
  • Recent session rx and tx support numeric and quoted-string values.
  • Smoke output no longer exposes account values or identifiers.

Compatibility

Session.RX and Session.TX now use octaspace.FlexInt64 instead of string.
Update code that uses these fields to call .Int64() or cast them to int64.

v0.1.0 — Production-Ready OctaSpace Go SDK

Choose a tag to compare

@secretpray secretpray released this 15 Apr 09:22
b2ad8dd

✨ Features

Core Client

  • Multi-URL failover — automatic failover to backup hosts on network errors (connection refused, DNS, TLS)
  • Connection pooling — tuned http.Transport with MaxIdleConnsPerHost=10 for connection reuse
  • Configurable timeout — per-request timeout via WithTimeout option
  • Automatic retries — exponential backoff (500ms, 1s, 2s) with configurable max retries
  • Pluggable logging — integrate with your logger via NewStdLogger or custom adapter

API Coverage

  • Full resource support: Network, Accounts, Apps, Nodes, Services (MR/VPN/Render), Sessions
  • Type-safe data structures with custom JSON unmarshaling (FlexInt64, BigInt)
  • Comprehensive error handling with typed errors (APIError, NetworkError) and helper functions

Developer Experience

  • Example functions — godoc examples for all major use cases
  • Well-tested — 40+ unit and integration tests covering core flows
  • CI/CD ready — GitHub Actions matrix testing (Go 1.20–1.23 × ubuntu/macos)

📦 What's Included

  • Complete OctaSpace API client library
  • Smoke test tool for validating against live API
  • Configurable retry/failover strategies for production workloads
  • Comprehensive documentation with inline examples

🔗 Links