Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,6 @@ message BillingDetails {
optional string company_name = 3;
optional string billing_email = 4;
sentry_protos.billing.v1.common.v1.Address billing_address = 5;
// The customer's tax registration number (e.g. VAT ID), if on file.
optional string tax_number = 6;
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ message CreateContractRequest {
// supported_month_intervals. If unset, defaults to the package's first
// supported interval.
uint32 month_interval = 6;
// The customer's tax registration number (e.g. VAT ID), used to determine
// tax treatment for this contract (for example, reverse charge for
// tax-registered businesses). Unset if none is on file.
optional string customer_tax_id = 7;
}

message CreateContractResponse {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ message RolloverContractRequest {
// The pending change to apply to the new contract, if any. Unset means no
// pending change is being applied during this rollover.
optional sentry_protos.billing.v1.common.v1.PendingChange pending_change = 5;
// The customer's tax registration number (e.g. VAT ID), used to determine
// tax treatment for this contract (for example, reverse charge for
// tax-registered businesses). Unset if none is on file.
optional string customer_tax_id = 6;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need this for rollover contract? We pass the invoice line items through this request. So doesn't it make more sense to make use of the customer_tax_id when determining the line_items to pass to this request?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@brendanhsentry im moving the tax calculation to upstream in the invoicer service rather than at the contract service. this changed the protos a bit. i'm preferring the protos field additions in #286 instead.

}

message RolloverContractResponse {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ pub struct BillingDetails {
pub billing_address: ::core::option::Option<
super::super::super::common::v1::Address,
>,
/// The customer's tax registration number (e.g. VAT ID), if on file.
#[prost(string, optional, tag = "6")]
pub tax_number: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct GetBillingDetailsRequest {
Expand Down
10 changes: 10 additions & 0 deletions rust/src/sentry_protos.billing.v1.services.contract.v1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -493,6 +493,11 @@ pub struct CreateContractRequest {
/// supported interval.
#[prost(uint32, tag = "6")]
pub month_interval: u32,
/// The customer's tax registration number (e.g. VAT ID), used to determine
/// tax treatment for this contract (for example, reverse charge for
/// tax-registered businesses). Unset if none is on file.
#[prost(string, optional, tag = "7")]
pub customer_tax_id: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct CreateContractResponse {
Expand Down Expand Up @@ -673,6 +678,11 @@ pub struct RolloverContractRequest {
pub pending_change: ::core::option::Option<
super::super::super::common::v1::PendingChange,
>,
/// The customer's tax registration number (e.g. VAT ID), used to determine
/// tax treatment for this contract (for example, reverse charge for
/// tax-registered businesses). Unset if none is on file.
#[prost(string, optional, tag = "6")]
pub customer_tax_id: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct RolloverContractResponse {
Expand Down
Loading