Files
zeekay 1df3ddf6bd Regenerate against the document the deployment answers for
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.
2026-09-05 18:55:38 -07:00

61 lines
2.2 KiB
Swift

//
// Delivery.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//
import Foundation
public struct Delivery: Sendable, Codable, ParameterConvertible, Hashable {
/** Data is the payload, base64-encoded. */
public var data: String?
/** Headers are the message headers, when any were published. */
public var headers: [String: [String]]?
/** Delivered is how many times a consumer has been handed this message (pulls only). */
public var numDelivered: Int64?
/** Remaining is how many messages follow this one for the consumer (pulls only). */
public var numPending: Int?
/** Sequence is the message's stream sequence. */
public var sequence: Int?
/** Subject is the org-relative subject the message was stored under. */
public var subject: String?
/** Timestamp is when the broker stored the message. */
public var timestamp: Date?
public init(data: String? = nil, headers: [String: [String]]? = nil, numDelivered: Int64? = nil, numPending: Int? = nil, sequence: Int? = nil, subject: String? = nil, timestamp: Date? = nil) {
self.data = data
self.headers = headers
self.numDelivered = numDelivered
self.numPending = numPending
self.sequence = sequence
self.subject = subject
self.timestamp = timestamp
}
public enum CodingKeys: String, CodingKey, CaseIterable {
case data
case headers
case numDelivered = "num_delivered"
case numPending = "num_pending"
case sequence
case subject
case timestamp
}
// Encodable protocol methods
public func encode(to encoder: Encoder) throws {
var container = encoder.container(keyedBy: CodingKeys.self)
try container.encodeIfPresent(data, forKey: .data)
try container.encodeIfPresent(headers, forKey: .headers)
try container.encodeIfPresent(numDelivered, forKey: .numDelivered)
try container.encodeIfPresent(numPending, forKey: .numPending)
try container.encodeIfPresent(sequence, forKey: .sequence)
try container.encodeIfPresent(subject, forKey: .subject)
try container.encodeIfPresent(timestamp, forKey: .timestamp)
}
}