OBJECT

Subscription

link GraphQL Schema definition

1type Subscription {
2id: Int!
3
4# All elements are always returned
5attentionReasons: [AttentionReason!]!
6
7interval: DateInterval!
8
9needsAttention: Boolean!
10
11# Next day when the order should be created according to schedule and selected
12# interval.
13#
14# Arguments
15# format: (self-explanatory)
16nextOrderDate(format: String = "Y-m-d"): String!
17
18# Next day when the order creation will be attempted. Takes last failures and
19# retrial mechanics into account.
20#
21# Arguments
22# format: (self-explanatory)
23nextRetryDate(format: String = "Y-m-d"): String!
24
25# Number of failes tries to create the order for the last scheduled order date.
26tries: Int!
27
28# In the eventuality that the payment requires a confirmation notification,
29# it shows that it cannot be processed again
30isWaitingForPayment: Boolean!
31
32# Required permission: Subscription.internalComment:read
33internalComment: String
34
35discount: Float
36
37# Arguments
38# format: ISO-8601
39createdAt(format: String = "Y-m-d\\TH:i:sP"): String!
40
41# Arguments
42# format: ISO-8601
43updatedAt(format: String = "Y-m-d\\TH:i:sP"): String!
44
45# Required permission: Subscription:read
46#
47# Store restrictions apply.
48contract: SubscriptionContract!
49
50# Recurring orders generated accordingly to subscription schedule.
51#
52# Required permission: Order:read
53#
54# Limit must be in range 1 - 200
55#
56# Store restrictions apply.
57#
58# Arguments
59# where: (self-explanatory)
60# sort: (self-explanatory)
61# limit: (self-explanatory)
62# page: (self-explanatory)
63generatedOrders(
64where: OrderFilter,
65sort: [OrderSort!] = [orderDate_DESC],
66limit: Int = 20,
67page: Int = 1
68): [Order!]!
69
70# Required permission: Subscription:read
71#
72# All elements are always returned
73lines: [SubscriptionLine!]!
74
75# Required permission: SubscriptionPlan:read
76#
77# Store restrictions apply.
78plan: SubscriptionPlan
79
80status: SubscriptionStatus!
81
82}