-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Force expand PaymentsForInvoice fields. Rerun generator. (#71)
- Loading branch information
Showing
24 changed files
with
553 additions
and
103 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
// Copyright ©, 2023-present, Lightspark Group, Inc. - All Rights Reserved | ||
package objects | ||
|
||
import ( | ||
"encoding/json" | ||
"fmt" | ||
) | ||
|
||
// AuditLogActor Audit log actor who called the GraphQL mutation | ||
type AuditLogActor interface { | ||
Entity | ||
|
||
// GetTypename The typename of the object | ||
GetTypename() string | ||
} | ||
|
||
func AuditLogActorUnmarshal(data map[string]interface{}) (AuditLogActor, error) { | ||
if data == nil { | ||
return nil, nil | ||
} | ||
|
||
dataJSON, err := json.Marshal(data) | ||
if err != nil { | ||
return nil, err | ||
} | ||
|
||
switch data["__typename"].(string) { | ||
case "ApiToken": | ||
var apiToken ApiToken | ||
if err := json.Unmarshal(dataJSON, &apiToken); err != nil { | ||
return nil, err | ||
} | ||
return apiToken, nil | ||
|
||
default: | ||
return nil, fmt.Errorf("unknown AuditLogActor type: %s", data["__typename"]) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
// Copyright ©, 2023-present, Lightspark Group, Inc. - All Rights Reserved | ||
package objects | ||
|
||
// CancelInvoiceInput The unique identifier of the Invoice that should be cancelled. The invoice is supposed to be open, not settled and not expired. | ||
type CancelInvoiceInput struct { | ||
InvoiceId string `json:"cancel_invoice_input_invoice_id"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// Copyright ©, 2023-present, Lightspark Group, Inc. - All Rights Reserved | ||
package objects | ||
|
||
type IncomingPaymentsForInvoiceQueryInput struct { | ||
InvoiceId string `json:"incoming_payments_for_invoice_query_input_invoice_id"` | ||
|
||
// Statuses An optional filter to only query outgoing payments of given statuses. | ||
Statuses *[]TransactionStatus `json:"incoming_payments_for_invoice_query_input_statuses"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
// Copyright ©, 2023-present, Lightspark Group, Inc. - All Rights Reserved | ||
package objects | ||
|
||
type IncomingPaymentsForInvoiceQueryOutput struct { | ||
Payments []IncomingPayment `json:"incoming_payments_for_invoice_query_output_payments"` | ||
} | ||
|
||
const ( | ||
IncomingPaymentsForInvoiceQueryOutputFragment = ` | ||
fragment IncomingPaymentsForInvoiceQueryOutputFragment on IncomingPaymentsForInvoiceQueryOutput { | ||
__typename | ||
incoming_payments_for_invoice_query_output_payments: payments { | ||
__typename | ||
incoming_payment_id: id | ||
incoming_payment_created_at: created_at | ||
incoming_payment_updated_at: updated_at | ||
incoming_payment_status: status | ||
incoming_payment_resolved_at: resolved_at | ||
incoming_payment_amount: amount { | ||
__typename | ||
currency_amount_original_value: original_value | ||
currency_amount_original_unit: original_unit | ||
currency_amount_preferred_currency_unit: preferred_currency_unit | ||
currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded | ||
currency_amount_preferred_currency_value_approx: preferred_currency_value_approx | ||
} | ||
incoming_payment_transaction_hash: transaction_hash | ||
incoming_payment_is_uma: is_uma | ||
incoming_payment_destination: destination { | ||
id | ||
} | ||
incoming_payment_payment_request: payment_request { | ||
id | ||
} | ||
incoming_payment_uma_post_transaction_data: uma_post_transaction_data { | ||
__typename | ||
post_transaction_data_utxo: utxo | ||
post_transaction_data_amount: amount { | ||
__typename | ||
currency_amount_original_value: original_value | ||
currency_amount_original_unit: original_unit | ||
currency_amount_preferred_currency_unit: preferred_currency_unit | ||
currency_amount_preferred_currency_value_rounded: preferred_currency_value_rounded | ||
currency_amount_preferred_currency_value_approx: preferred_currency_value_approx | ||
} | ||
} | ||
} | ||
} | ||
` | ||
) |
Oops, something went wrong.