Skip to content

Commit

Permalink
Add support for columns on Reporting resources
Browse files Browse the repository at this point in the history
  • Loading branch information
remi-stripe committed Mar 14, 2019
1 parent 1e0db5d commit 76c22bf
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
14 changes: 8 additions & 6 deletions reporting_reportrun.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@ const (

// ReportRunParametersParams is the set of parameters that can be used when creating a report run.
type ReportRunParametersParams struct {
ConnectedAccount *string `form:"connected_account"`
Currency *string `form:"currency"`
IntervalEnd *int64 `form:"interval_end"`
IntervalStart *int64 `form:"interval_start"`
Payout *string `form:"payout"`
ReportingCategory *string `form:"reporting_category"`
Columns []*string `form:"columns"`
ConnectedAccount *string `form:"connected_account"`
Currency *string `form:"currency"`
IntervalEnd *int64 `form:"interval_end"`
IntervalStart *int64 `form:"interval_start"`
Payout *string `form:"payout"`
ReportingCategory *string `form:"reporting_category"`
}

// ReportRunParams is the set of parameters that can be used when creating a report run.
Expand All @@ -36,6 +37,7 @@ type ReportRunListParams struct {

// ReportRunParameters describes the parameters hash on a report run.
type ReportRunParameters struct {
Columns []string `json:"columns"`
ConnectedAccount string `json:"connected_account"`
Currency Currency `json:"currency"`
IntervalEnd int64 `json:"interval_end"`
Expand Down
17 changes: 9 additions & 8 deletions reporting_reporttype.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@ type ReportTypeParams struct {

// ReportType is the resource representing a report type.
type ReportType struct {
Created int64 `json:"created"`
DataAvailableEnd int64 `json:"data_available_end"`
DataAvailableStart int64 `json:"data_available_start"`
ID string `json:"id"`
Name string `json:"name"`
Object string `json:"object"`
Updated int64 `json:"updated"`
Version int64 `json:"version"`
DefaultColumns []string `json:"default_columns"`
Created int64 `json:"created"`
DataAvailableEnd int64 `json:"data_available_end"`
DataAvailableStart int64 `json:"data_available_start"`
ID string `json:"id"`
Name string `json:"name"`
Object string `json:"object"`
Updated int64 `json:"updated"`
Version int64 `json:"version"`
}

// ReportTypeList is a list of report types as retrieved from a list endpoint.
Expand Down

0 comments on commit 76c22bf

Please sign in to comment.