StoreApiService class
Builds the /api/v1 REST surface over any OmnyStoreApi.
Because it is written against the interface rather than a concrete store, the same routes serve an embedded single-process registry, a federating hub with a dozen nodes, or (in tests) a store wired to in-memory everything — with no conditional code anywhere in the handlers.
Endpoints
GET /health
GET /api/v1/organizations POST /api/v1/organizations
GET /api/v1/organizations/{id} PUT /api/v1/organizations/{id}
DELETE /api/v1/organizations/{id}
GET /api/v1/organizations/{id}/projects
GET /api/v1/organizations/{id}/packages
GET /api/v1/projects POST /api/v1/projects
GET /api/v1/projects/{id} PUT /api/v1/projects/{id}
DELETE /api/v1/projects/{id}
GET /api/v1/projects/{id}/packages
GET /api/v1/packages POST /api/v1/packages
GET /api/v1/packages/{id} PUT /api/v1/packages/{id}
DELETE /api/v1/packages/{id}
GET /api/v1/packages/{id}/releases POST /api/v1/packages/{id}/releases
GET /api/v1/packages/{id}/releases/latest
GET /api/v1/packages/{id}/releases/{version}
GET /api/v1/packages/{id}/updates
GET /api/v1/packages/{id}/downloads
GET /api/v1/packages/{id}/downloads/stats
GET /api/v1/releases/{id} PUT /api/v1/releases/{id}
DELETE /api/v1/releases/{id}
POST /api/v1/releases/{id}/promote
GET /api/v1/releases/{id}/assets POST /api/v1/releases/{id}/assets
GET /api/v1/assets/{id} DELETE /api/v1/assets/{id}
GET /api/v1/assets/{id}/download
GET /api/v1/providers
Downloads redirect when they can. GET /assets/{id}/download answers
302 at a presigned bucket URL if the holding provider can issue one, and
streams the bytes itself otherwise — with Range and 206 Partial Content
supported either way, so a client can resume an interrupted download.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
build(
OmnyStoreApi store, {String name = 'omnystore-api', String mount = basePath, Logger logger = const NoopLogger(), void writeGuard(HubRequest request)?, Duration redirectLifetime = const Duration(minutes: 15), bool recordDownloads = true, bool captureClientAddress = true}) → RouterService -
Builds the router for
store. -
health(
OmnyStoreApi store, {String name = 'omnystore-health', Logger logger = const NoopLogger()}) → HandlerService -
Builds the
GET /healthservice.
Constants
- basePath → const String
- The path prefix every versioned route lives under.
- healthPath → const String
- The unversioned health-check path.