CalendarPost class

Constructors

CalendarPost({String? body, String? channel, int? createdAt, String? error, String? id, int? publishedAt, int? scheduledAt, String? status, String? title, int? updatedAt})
Returns a new CalendarPost instance.

Properties

body ↔ String?
Body is the post text. Required.
getter/setter pair
channel ↔ String?
Channel is the target network: x, facebook, instagram, linkedin, tiktok, youtube or threads. Required — a post must name where it goes.
getter/setter pair
createdAt ↔ int?
CreatedAt is unix seconds when the post was added, server-assigned and never rewritten.
getter/setter pair
error ↔ String?
Error is the exact reason the last publish attempt failed — the honest record behind a "failed" status, never a faked success.
getter/setter pair
hashCode → int
The hash code for this object.
no setteroverride
id ↔ String?
ID is the server-assigned post id ("cal_" + 128 random bits).
getter/setter pair
publishedAt ↔ int?
PublishedAt is when the publish succeeded; 0 until it does.
getter/setter pair
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scheduledAt ↔ int?
ScheduledAt is the unix publish time; 0 leaves the post a draft, and any value makes it "scheduled" for the durable sweep to pick up.
getter/setter pair
status ↔ String?
Status is draft, scheduled, published, failed or canceled. Server-owned.
getter/setter pair
title ↔ String?
Title is the post's internal label, capped at 1024 bytes.
getter/setter pair
updatedAt ↔ int?
UpdatedAt is unix seconds of the last write, server-assigned. The durable sweep writes too — claiming a due post, publishing it and recording a failure each bump it — so this moves without anyone editing the post.
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override

Static Methods

fromJson(dynamic value) → CalendarPost?
Returns a new CalendarPost instance and imports its values from value if it's a Map, null otherwise.
listFromJson(dynamic json, {bool growable = false}) → List<CalendarPost>
mapFromJson(dynamic json) → Map<String, CalendarPost>
mapListFromJson(dynamic json, {bool growable = false}) → Map<String, List<CalendarPost>>

Constants

requiredKeys → const Set<String>
The list of required keys that must be present in a JSON.