| 1 | // @generated by protoc-gen-es v1.10.0 with parameter "target=ts,import_extension=none" |
| 2 | // @generated from file types/v1/price.proto (package types.v1, syntax proto3) |
| 3 | /* eslint-disable */ |
| 4 | // @ts-nocheck |
| 5 | |
| 6 | import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf"; |
| 7 | import { Message, proto3, protoInt64, Timestamp } from "@bufbuild/protobuf"; |
| 8 | |
| 9 | /** |
| 10 | * @generated from message types.v1.Price |
| 11 | */ |
| 12 | export class Price extends Message<Price> { |
| 13 | /** |
| 14 | * @generated from field: google.protobuf.Timestamp created_at = 100; |
| 15 | */ |
| 16 | createdAt?: Timestamp; |
| 17 | |
| 18 | /** |
| 19 | * @generated from field: string stripe_id = 1; |
| 20 | */ |
| 21 | stripeId = ""; |
| 22 | |
| 23 | /** |
| 24 | * @generated from field: string currency = 2; |
| 25 | */ |
| 26 | currency = ""; |
| 27 | |
| 28 | /** |
| 29 | * @generated from field: int64 unit_amount = 3; |
| 30 | */ |
| 31 | unitAmount = protoInt64.zero; |
| 32 | |
| 33 | /** |
| 34 | * @generated from field: types.v1.Price.Recurring recurring = 4; |
| 35 | */ |
| 36 | recurring?: Price_Recurring; |
| 37 | |
| 38 | /** |
| 39 | * @generated from field: string lookup_key = 5; |
| 40 | */ |
| 41 | lookupKey = ""; |
| 42 | |
| 43 | constructor(data?: PartialMessage<Price>) { |
| 44 | super(); |
| 45 | proto3.util.initPartial(data, this); |
| 46 | } |
| 47 | |
| 48 | static readonly runtime: typeof proto3 = proto3; |
| 49 | static readonly typeName = "types.v1.Price"; |
| 50 | static readonly fields: FieldList = proto3.util.newFieldList(() => [ |
| 51 | { no: 100, name: "created_at", kind: "message", T: Timestamp }, |
| 52 | { no: 1, name: "stripe_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, |
| 53 | { no: 2, name: "currency", kind: "scalar", T: 9 /* ScalarType.STRING */ }, |
| 54 | { no: 3, name: "unit_amount", kind: "scalar", T: 3 /* ScalarType.INT64 */ }, |
| 55 | { no: 4, name: "recurring", kind: "message", T: Price_Recurring }, |
| 56 | { no: 5, name: "lookup_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, |
| 57 | ]); |
| 58 | |
| 59 | static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Price { |
| 60 | return new Price().fromBinary(bytes, options); |
| 61 | } |
| 62 | |
| 63 | static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Price { |
| 64 | return new Price().fromJson(jsonValue, options); |
| 65 | } |
| 66 | |
| 67 | static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Price { |
| 68 | return new Price().fromJsonString(jsonString, options); |
| 69 | } |
| 70 | |
| 71 | static equals(a: Price | PlainMessage<Price> | undefined, b: Price | PlainMessage<Price> | undefined): boolean { |
| 72 | return proto3.util.equals(Price, a, b); |
| 73 | } |
| 74 | } |
| 75 | |
| 76 | /** |
| 77 | * @generated from message types.v1.Price.Recurring |
| 78 | */ |
| 79 | export class Price_Recurring extends Message<Price_Recurring> { |
| 80 | /** |
| 81 | * @generated from field: string interval = 1; |
| 82 | */ |
| 83 | interval = ""; |
| 84 | |
| 85 | /** |
| 86 | * @generated from field: int64 interval_count = 2; |
| 87 | */ |
| 88 | intervalCount = protoInt64.zero; |
| 89 | |
| 90 | /** |
| 91 | * @generated from field: int64 trial_period_days = 3; |
| 92 | */ |
| 93 | trialPeriodDays = protoInt64.zero; |
| 94 | |
| 95 | constructor(data?: PartialMessage<Price_Recurring>) { |
| 96 | super(); |
| 97 | proto3.util.initPartial(data, this); |
| 98 | } |
| 99 | |
| 100 | static readonly runtime: typeof proto3 = proto3; |
| 101 | static readonly typeName = "types.v1.Price.Recurring"; |
| 102 | static readonly fields: FieldList = proto3.util.newFieldList(() => [ |
| 103 | { no: 1, name: "interval", kind: "scalar", T: 9 /* ScalarType.STRING */ }, |
| 104 | { no: 2, name: "interval_count", kind: "scalar", T: 3 /* ScalarType.INT64 */ }, |
| 105 | { no: 3, name: "trial_period_days", kind: "scalar", T: 3 /* ScalarType.INT64 */ }, |
| 106 | ]); |
| 107 | |
| 108 | static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Price_Recurring { |
| 109 | return new Price_Recurring().fromBinary(bytes, options); |
| 110 | } |
| 111 | |
| 112 | static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Price_Recurring { |
| 113 | return new Price_Recurring().fromJson(jsonValue, options); |
| 114 | } |
| 115 | |
| 116 | static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Price_Recurring { |
| 117 | return new Price_Recurring().fromJsonString(jsonString, options); |
| 118 | } |
| 119 | |
| 120 | static equals(a: Price_Recurring | PlainMessage<Price_Recurring> | undefined, b: Price_Recurring | PlainMessage<Price_Recurring> | undefined): boolean { |
| 121 | return proto3.util.equals(Price_Recurring, a, b); |
| 122 | } |
| 123 | } |
| 124 |