AppsService class
App CRUD against /v1/app/* for the CLI's own commands (#30) — apps create / apps list, and init's offer-to-create. Call-injected Dio
(never ApiClient.forKey itself) — the KeysService contract, not
upload_service.dart's: never calls exit(), every failure becomes a
thrown AuthCliFault. A connectivity failure (no response at all) is
rethrown as the raw DioException for the caller to report.
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
-
create(
{required Dio apiDio, required String name, required String packageName}) → Future< Map< String, dynamic> > -
Two calls in a fixed order —
whoamibeforecreate— so the account'stype/organizationIddecideownerTypethe waylib/ui/screens/create_app/_state.dartdoes, rather than the caller having to know it.FakeAdapter.callsinapps_service_test.dartproves the order. Amemberof an organization is refused locally, before the POST — the backend's ownFORBIDDEN:403 (appCreateService, #30) is the backstop, not the only gate, the way an already-stalewhoamiread could otherwise cost a wasted round trip. Individuals are never refused here — there is no "member" concept on an individual account. -
isRegistered(
{required Dio apiDio, required String packageName}) → Future< bool> -
Built on list — a pure client-side filter, no extra HTTP call (the
findByNamepattern,keys_service.dart). Used byinit's offer-to-create so it never fires the prompt for a package already on the account. -
list(
{required Dio apiDio}) → Future< Map< String, dynamic> > -
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 Properties
- ins → AppsService
-
final