-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Define cloud billing event types and codes #6037
Conversation
lib/events/codes.go
Outdated
@@ -294,6 +294,14 @@ const ( | |||
MFADeviceAddEventCode = "T1006I" | |||
// MFADeviceDeleteEventCode is an event code for users deleting MFA devices. | |||
MFADeviceDeleteEventCode = "T1007I" | |||
// BillingCardCreateCode is emitted when a user creates a new credit card. | |||
BillingCardCreateCode = "T1008I" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you look at numbers, the T10xxx
is used for user login events. The billing deserve own group.
Lets use TBL
prefix for that:
TBL01I
TBL02I
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revised
251dae6
to
b51d453
Compare
api/types/events/events.proto
Outdated
@@ -1263,6 +1297,9 @@ message OneOf { | |||
events.SessionUpload SessionUpload = 43; | |||
events.MFADeviceAdd MFADeviceAdd = 44; | |||
events.MFADeviceDelete MFADeviceDelete = 45; | |||
events.BillingAccountUpdate BillingAccountUpdate = 46; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BillingAcountUpdate
-> BillingInformationUpdate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with comments
lib/events/api.go
Outdated
// BillingCardUpdateEvent is emitted when a user updates an existing credit card. | ||
BillingCardUpdateEvent = "billing.update_card" | ||
// BillingAccountUpdateEvent is emitted when a user updates their billing account. | ||
BillingAccountUpdateEvent = "billing.update_account" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BillingAccountUpdate -> BillingInformationUpdate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revised
0d178fe
to
1cfe787
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bot.
63b02f5
to
0ac06d9
Compare
- Exported auth.clientUsername so it can be used in enterprise
- Stayed with convention and created seperate create(upsert) and delete event objects in proto file - Renamed event code numbers
0ac06d9
to
e192d27
Compare
* Exported auth.clientImpersonator and auth.clientUsername for use in e
part of https://github.com/gravitational/cloud/issues/442
Description