comAtprotoSpaceUpdateSpace function

Future<XRPCResponse<EmptyData>> comAtprotoSpaceUpdateSpace({
  1. required String space,
  2. required USpaceUpdateSpacePolicy policy,
  3. required ServiceContext $ctx,
  4. String? $service,
  5. Map<String, String>? $headers,
  6. Map<String, String>? $unknown,
})

Replace the policy of a space. Changing to a different policy type discards state held by the previous policy, such as a member list. Requires auth as the space authority, implemented by PDS.

Implementation

Future<XRPCResponse<EmptyData>> comAtprotoSpaceUpdateSpace({
  required String space,
  required USpaceUpdateSpacePolicy policy,
  required ServiceContext $ctx,
  String? $service,
  Map<String, String>? $headers,
  Map<String, String>? $unknown,
}) async => await $ctx.post(
  ns.comAtprotoSpaceUpdateSpace,
  service: $service,
  headers: {'Content-type': 'application/json', ...?$headers},
  body: {...?$unknown, 'space': space, 'policy': policy.toJson()},
);