Skip to content

Commit

Permalink
update GraphQL schema
Browse files Browse the repository at this point in the history
  • Loading branch information
znarf committed Nov 21, 2023
1 parent 454f9a1 commit 72d974c
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 15 deletions.
55 changes: 43 additions & 12 deletions src/graphql/schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ interface CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -726,11 +726,12 @@ enum OrderStatus {
PAID
ERROR
PROCESSING
REJECTED
ACTIVE
CANCELLED
PENDING
EXPIRED
PLEDGED
REJECTED
DISPUTED
REFUNDED
IN_REVIEW
Expand Down Expand Up @@ -2133,7 +2134,7 @@ type Collective implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -2397,7 +2398,7 @@ type Event implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -2661,7 +2662,7 @@ type Fund implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -2925,7 +2926,7 @@ type Organization implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -3189,7 +3190,7 @@ type Project implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -3453,7 +3454,12 @@ type Expense implements Transaction {
"""
Fee kept by the payment processor in the lowest unit of the currency of the host (ie. in cents)
"""
paymentProcessorFeeInHostCurrency: Int
paymentProcessorFeeInHostCurrency(
"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int

"""
The amount paid in tax (for example VAT) for this transaction
Expand All @@ -3473,6 +3479,11 @@ type Expense implements Transaction {
Fetch HOST_FEE transaction and integrate in calculation for retro-compatiblity.
"""
fetchHostFee: Boolean = false

"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int
amountInHostCurrency: Int
host: User
Expand Down Expand Up @@ -3553,6 +3564,11 @@ interface Transaction {
Fetch HOST_FEE transaction and integrate in calculation for retro-compatibility.
"""
fetchHostFee: Boolean = false

"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int
amountInHostCurrency: Int

Expand All @@ -3566,7 +3582,12 @@ interface Transaction {
fetchHostFee: Boolean = false
): Int
platformFeeInHostCurrency: Int
paymentProcessorFeeInHostCurrency: Int
paymentProcessorFeeInHostCurrency(
"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int
taxAmount: Int
taxInfo: TaxInfo
createdByUser: UserDetails
Expand Down Expand Up @@ -3623,7 +3644,12 @@ type Order implements Transaction {
"""
Fee kept by the payment processor in the lowest unit of the currency of the host (ie. in cents)
"""
paymentProcessorFeeInHostCurrency: Int
paymentProcessorFeeInHostCurrency(
"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int

"""
The amount paid in tax (for example VAT) for this transaction
Expand All @@ -3643,6 +3669,11 @@ type Order implements Transaction {
Fetch HOST_FEE transaction and integrate in calculation for retro-compatiblity.
"""
fetchHostFee: Boolean = false

"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Int
amountInHostCurrency: Int
host: User
Expand Down Expand Up @@ -3698,7 +3729,7 @@ type User implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down Expand Up @@ -3963,7 +3994,7 @@ type Vendor implements CollectiveInterface {
"""
Defines if a collective is pledged
"""
isPledged: Boolean @deprecated(reason: "2023-11-20: Pledged collectives do not exist anymore")
isPledged: Boolean
data: JSON @deprecated(reason: "2020-10-08: This field is not provided anymore and will return an empty object")

"""
Expand Down
17 changes: 14 additions & 3 deletions src/graphql/schemaV2.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -1114,11 +1114,12 @@ enum OrderStatus {
PAID
ERROR
PROCESSING
REJECTED
ACTIVE
CANCELLED
PENDING
EXPIRED
PLEDGED
REJECTED
DISPUTED
REFUNDED
IN_REVIEW
Expand Down Expand Up @@ -1163,12 +1164,22 @@ interface Transaction {
Fetch HOST_FEE transaction and integrate in calculation for retro-compatiblity.
"""
fetchHostFee: Boolean = false

"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Amount!
netAmountInHostCurrency(
"""
Fetch HOST_FEE transaction and integrate in calculation for retro-compatiblity.
"""
fetchHostFee: Boolean = false

"""
Fetch PAYMENT_PROCESSOR_FEE transaction for retro-compatiblity.
"""
fetchPaymentProcessorFee: Boolean = false
): Amount!
taxAmount: Amount!

Expand Down Expand Up @@ -5040,7 +5051,6 @@ enum ActivityType {
TICKET_CONFIRMED
ORDER_CANCELED_ARCHIVED_COLLECTIVE
ORDER_PENDING
ORDER_PENDING_CRYPTO
ORDER_PENDING_CONTRIBUTION_NEW
ORDER_PENDING_CONTRIBUTION_REMINDER
ORDER_PROCESSING
Expand Down Expand Up @@ -5085,6 +5095,7 @@ enum ActivityType {
COLLECTIVE_VIRTUAL_CARD_CREATED
SUBSCRIPTION_CONFIRMED
COLLECTIVE_COMMENT_CREATED
ORDER_PENDING_CRYPTO
BACKYOURSTACK_DISPATCH_CONFIRMED
}

Expand Down Expand Up @@ -13268,7 +13279,6 @@ enum ActivityAndClassesType {
TICKET_CONFIRMED
ORDER_CANCELED_ARCHIVED_COLLECTIVE
ORDER_PENDING
ORDER_PENDING_CRYPTO
ORDER_PENDING_CONTRIBUTION_NEW
ORDER_PENDING_CONTRIBUTION_REMINDER
ORDER_PROCESSING
Expand Down Expand Up @@ -13313,6 +13323,7 @@ enum ActivityAndClassesType {
COLLECTIVE_VIRTUAL_CARD_CREATED
SUBSCRIPTION_CONFIRMED
COLLECTIVE_COMMENT_CREATED
ORDER_PENDING_CRYPTO
BACKYOURSTACK_DISPATCH_CONFIRMED
COLLECTIVE
EXPENSES
Expand Down

0 comments on commit 72d974c

Please sign in to comment.