All URIs are relative to https://api.blockchainapi.com/v1
| Method | HTTP request | Description |
|---|---|---|
| GetCCPayment | Get /checkout/v1/project/{project_id}/payment/{payment_identifier} | Get a payment |
| ListAllCCPayments | Get /checkout/v1/payments | List all payments |
| ListCCProjectPayments | Get /checkout/v1/project/{project_id}/payments | List a project's payments |
CCPayment GetCCPayment(ctx, projectId, paymentIdentifier).Execute()
Get a payment
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
projectId := "project_WDQskRIfHQxj53N5mk5K" // string | The ID of the project. Created and returned when a project is created.
paymentIdentifier := "["payment_97jA1szpVjrSI5EvOb5zxNQFq5CfrC"]" // string | You can supply either `payment_id` or `payment_validation_code`. The `payment_id` is only visible by you and uniquely identifies a payment. The `payment_validation_code` is shown exclusively to the customer and the owner of the project. It can be used to redeem a payment. You can verify a payment by pulling the payment with the `payment_validation_code`.
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CCPaymentApi.GetCCPayment(context.Background(), projectId, paymentIdentifier).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CCPaymentApi.GetCCPayment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetCCPayment`: CCPayment
fmt.Fprintf(os.Stdout, "Response from `CCPaymentApi.GetCCPayment`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | The ID of the project. Created and returned when a project is created. | |
| paymentIdentifier | string | You can supply either `payment_id` or `payment_validation_code`. The `payment_id` is only visible by you and uniquely identifies a payment. The `payment_validation_code` is shown exclusively to the customer and the owner of the project. It can be used to redeem a payment. You can verify a payment by pulling the payment with the `payment_validation_code`. |
Other parameters are passed through a pointer to a apiGetCCPaymentRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]CCPayment ListAllCCPayments(ctx).Execute()
List all payments
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CCPaymentApi.ListAllCCPayments(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CCPaymentApi.ListAllCCPayments``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListAllCCPayments`: []CCPayment
fmt.Fprintf(os.Stdout, "Response from `CCPaymentApi.ListAllCCPayments`: %v\n", resp)
}This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiListAllCCPaymentsRequest struct via the builder pattern
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]CCPayment ListCCProjectPayments(ctx, projectId).UNKNOWN_PARAMETER_NAME(UNKNOWN_PARAMETER_NAME).Execute()
List a project's payments
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
projectId := "project_WDQskRIfHQxj53N5mk5K" // string | The ID of the project. Created and returned when a project is created.
UNKNOWN_PARAMETER_NAME := TODO // | Filter payments by a user's wallet identifier (i.e., Solana public key) (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.CCPaymentApi.ListCCProjectPayments(context.Background(), projectId).UNKNOWN_PARAMETER_NAME(UNKNOWN_PARAMETER_NAME).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `CCPaymentApi.ListCCProjectPayments``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListCCProjectPayments`: []CCPayment
fmt.Fprintf(os.Stdout, "Response from `CCPaymentApi.ListCCProjectPayments`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | The ID of the project. Created and returned when a project is created. |
Other parameters are passed through a pointer to a apiListCCProjectPaymentsRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
UNKNOWN_PARAMETER_NAME | **** | Filter payments by a user's wallet identifier (i.e., Solana public key) |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]