mirror of
https://github.com/hanzoai/swift-sdk.git
synced 2026-10-30 18:20:19 +00:00
The projection these were generated from predated the compute migration, so they described /v1/visor — which the API serves at zero paths now. No /v1/visor path survives here.
59 lines
2.3 KiB
Swift
59 lines
2.3 KiB
Swift
//
|
|
// SocialAccount.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct SocialAccount: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** CreatedAt is when the account was connected, as a unix timestamp in seconds. */
|
|
public var createdAt: Int64?
|
|
/** Handle is the account's public name on the network, as the customer knows it. Trimmed and bounded at 1024 characters. Example: \"@acme\" */
|
|
public var handle: String?
|
|
/** ID is the account's identifier, minted on connect and the id every later call addresses it by. Example: \"acct_7f3c1a\" */
|
|
public var id: String?
|
|
/** Provider is the network this account is on: x, facebook, instagram, linkedin, tiktok, youtube or threads. Example: \"x\" */
|
|
public var provider: String?
|
|
/** Status is the connection lifecycle: connected, disconnected or error. Only a connected account is a publish target. */
|
|
public var status: String?
|
|
/** UpdatedAt is when the account row last changed, as a unix timestamp in seconds. The listing is ordered by it, newest first. */
|
|
public var updatedAt: Int64?
|
|
|
|
public init(createdAt: Int64? = nil, handle: String? = nil, id: String? = nil, provider: String? = nil, status: String? = nil, updatedAt: Int64? = nil) {
|
|
self.createdAt = createdAt
|
|
self.handle = handle
|
|
self.id = id
|
|
self.provider = provider
|
|
self.status = status
|
|
self.updatedAt = updatedAt
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case createdAt
|
|
case handle
|
|
case id
|
|
case provider
|
|
case status
|
|
case updatedAt
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(createdAt, forKey: .createdAt)
|
|
try container.encodeIfPresent(handle, forKey: .handle)
|
|
try container.encodeIfPresent(id, forKey: .id)
|
|
try container.encodeIfPresent(provider, forKey: .provider)
|
|
try container.encodeIfPresent(status, forKey: .status)
|
|
try container.encodeIfPresent(updatedAt, forKey: .updatedAt)
|
|
}
|
|
}
|
|
|
|
|
|
@available(iOS 13, tvOS 13, watchOS 6, macOS 10.15, *)
|
|
extension SocialAccount: Identifiable {}
|