Skip to content

Instantly share code, notes, and snippets.

@xreiju
Last active December 24, 2016 02:10
Show Gist options
  • Save xreiju/c554aa7139d23f78f3b524286a3d9bb0 to your computer and use it in GitHub Desktop.
Save xreiju/c554aa7139d23f78f3b524286a3d9bb0 to your computer and use it in GitHub Desktop.
The document of Misskey.xyz.

Postの扱い方

Swiftではこのようにプロパティを用意してあげる

var created_at: Date = Date.distantPast
var media_ids: [String]?
var reply_to_id: String?
var repost_id: String?
var text: String?
var user: MKUser?
var app_id: String?
var likes_count: Int?
var repost_count: Int?
var id: String = ""
var is_liked: Bool = false

Userの扱い方

Swiftではこのようにプロパティを用意してあげる

var birthday: Date?
var created_at: Date = Date.distantPast
var bio: String?
var followers_count: Int = 0
var following_count: Int = 0
var links: String?
var location: String?
var name: String = ""
var posts_count: Int = 0
var drive_capacity:Int = 0
var username: String = ""
var likes_count: Int = 0
var liked_count: Int = 0
var avatar_id: String?
var banner_id: String?
var id: String = ""
var avatar_url: URL?
var banner_url: URL?
var is_following: Bool = false
var is_followed: Bool = true
var following_you_know_count: Int = 0
var followers_you_know_count: Int = 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment