Skip to content

Latest commit

 

History

History
143 lines (89 loc) · 4.41 KB

File metadata and controls

143 lines (89 loc) · 4.41 KB

\BillingMeterEventsAPI

All URIs are relative to https://connto.getopenpay.com

Method HTTP request Description
CreateBillingMeterEvent Post /billing/meter-events/ Create Billing Meter Event
ListBillingMeterEventSummaries Post /billing/meter-events/list List Billing Meter Event Summaries

CreateBillingMeterEvent

BillingMeterEventExternal CreateBillingMeterEvent(ctx).CreateBillingMeterEventRequest(createBillingMeterEventRequest).Execute()

Create Billing Meter Event

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/getopenpay/getopenpay-go"
)

func main() {
	createBillingMeterEventRequest := *openapiclient.NewCreateBillingMeterEventRequest("EventName_example", map[string]interface{}(123)) // CreateBillingMeterEventRequest | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.BillingMeterEventsAPI.CreateBillingMeterEvent(context.Background()).CreateBillingMeterEventRequest(createBillingMeterEventRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `BillingMeterEventsAPI.CreateBillingMeterEvent``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `CreateBillingMeterEvent`: BillingMeterEventExternal
	fmt.Fprintf(os.Stdout, "Response from `BillingMeterEventsAPI.CreateBillingMeterEvent`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiCreateBillingMeterEventRequest struct via the builder pattern

Name Type Description Notes
createBillingMeterEventRequest CreateBillingMeterEventRequest

Return type

BillingMeterEventExternal

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ListBillingMeterEventSummaries

ListResponseBillingMeterSummary ListBillingMeterEventSummaries(ctx).ListBillingMeterEventSummariesRequest(listBillingMeterEventSummariesRequest).Execute()

List Billing Meter Event Summaries

Example

package main

import (
	"context"
	"fmt"
	"os"
    "time"
	openapiclient "github.com/getopenpay/getopenpay-go"
)

func main() {
	listBillingMeterEventSummariesRequest := *openapiclient.NewListBillingMeterEventSummariesRequest("CustomerId_example", time.Now(), "MeterId_example", time.Now()) // ListBillingMeterEventSummariesRequest | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.BillingMeterEventsAPI.ListBillingMeterEventSummaries(context.Background()).ListBillingMeterEventSummariesRequest(listBillingMeterEventSummariesRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `BillingMeterEventsAPI.ListBillingMeterEventSummaries``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListBillingMeterEventSummaries`: ListResponseBillingMeterSummary
	fmt.Fprintf(os.Stdout, "Response from `BillingMeterEventsAPI.ListBillingMeterEventSummaries`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiListBillingMeterEventSummariesRequest struct via the builder pattern

Name Type Description Notes
listBillingMeterEventSummariesRequest ListBillingMeterEventSummariesRequest

Return type

ListResponseBillingMeterSummary

Authorization

HTTPBearer

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]