emitEvent method

Future<XRPCResponse<ModEventView>> emitEvent({
  1. required UEmitEventEvent event,
  2. required UEmitEventSubject subject,
  3. List<String>? subjectBlobCids,
  4. required String createdBy,
  5. Map<String, String>? $unknown,
  6. Map<String, String>? $headers,
  7. PostClient? $client,
})

Implementation

Future<XRPCResponse<ModEventView>> emitEvent({
  required UEmitEventEvent event,
  required UEmitEventSubject subject,
  List<String>? subjectBlobCids,
  required String createdBy,
  Map<String, String>? $unknown,
  Map<String, String>? $headers,
  PostClient? $client,
}) async =>
    await _ctx.post<ModEventView>(
      ns.toolsOzoneModerationEmitEvent,
      headers: $headers,
      body: {
        'event': event.toJson(),
        'subject': subject.toJson(),
        if (subjectBlobCids != null) 'subjectBlobCids': subjectBlobCids,
        'createdBy': createdBy,
        ...?$unknown,
      },
      to: const ModEventViewConverter().fromJson,
      client: $client,
    );