Skip to content

Commit

Permalink
Add rights distribution corporate action type (#280)
Browse files Browse the repository at this point in the history
  • Loading branch information
gnvk authored Apr 26, 2024
1 parent a7cc8a8 commit 5021269
Show file tree
Hide file tree
Showing 3 changed files with 367 additions and 169 deletions.
12 changes: 12 additions & 0 deletions marketdata/entities.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,17 @@ type WorthlessRemoval struct {
ProcessDate civil.Date `json:"process_date"`
}

type RightsDistribution struct {
SourceSymbol string `json:"source_symbol"`
NewSymbol string `json:"new_symbol"`
Rate float64 `json:"rate"`
ProcessDate civil.Date `json:"process_date"`
ExDate civil.Date `json:"ex_date"`
PayableDate civil.Date `json:"payable_date,omitempty"`
RecordDate *civil.Date `json:"record_date,omitempty"`
ExpirationDate *civil.Date `json:"expiration_date,omitempty"`
}

// CorporateActions contains corporate actions grouped by type
type CorporateActions struct {
ReverseSplits []ReverseSplit `json:"reverse_splits,omitempty"`
Expand All @@ -356,6 +367,7 @@ type CorporateActions struct {
SpinOffs []SpinOff `json:"spin_offs,omitempty"`
NameChanges []NameChange `json:"name_changes,omitempty"`
WorthlessRemovals []WorthlessRemoval `json:"worthless_removals,omitempty"`
RightsDistributions []RightsDistribution `json:"rights_distributions,omitempty"`
}

// OptionTrade is an option trade that happened on the market
Expand Down
Loading

0 comments on commit 5021269

Please sign in to comment.