Skip to content
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

feat: Add support for granular repricing configurations via SkuGroups in Cloud Channel Repricing APIs #3718

Merged
merged 6 commits into from
Dec 9, 2022
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@ option java_multiple_files = true;
option java_outer_classname = "ChannelPartnerLinksProto";
option java_package = "com.google.cloud.channel.v1";

// The level of granularity the [ChannelPartnerLink][google.cloud.channel.v1.ChannelPartnerLink] will display.
// The level of granularity the
// [ChannelPartnerLink][google.cloud.channel.v1.ChannelPartnerLink] will
// display.
enum ChannelPartnerLinkView {
// The default / unset value.
// The API will default to the BASIC view.
Expand Down Expand Up @@ -72,24 +74,29 @@ message ChannelPartnerLink {
string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];

// Required. Cloud Identity ID of the linked reseller.
string reseller_cloud_identity_id = 2 [(google.api.field_behavior) = REQUIRED];
string reseller_cloud_identity_id = 2
[(google.api.field_behavior) = REQUIRED];

// Required. State of the channel partner link.
ChannelPartnerLinkState link_state = 3 [(google.api.field_behavior) = REQUIRED];
ChannelPartnerLinkState link_state = 3
[(google.api.field_behavior) = REQUIRED];

// Output only. URI of the web page where partner accepts the link invitation.
string invite_link_uri = 4 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Timestamp of when the channel partner link is created.
google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 5
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Timestamp of when the channel partner link is updated.
google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp update_time = 6
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Public identifier that a customer must use to generate a transfer token
// to move to this distributor-reseller combination.
// Output only. Public identifier that a customer must use to generate a
// transfer token to move to this distributor-reseller combination.
string public_id = 7 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Cloud Identity info of the channel partner (IR).
CloudIdentityInfo channel_partner_cloud_identity_info = 8 [(google.api.field_behavior) = OUTPUT_ONLY];
}
CloudIdentityInfo channel_partner_cloud_identity_info = 8
[(google.api.field_behavior) = OUTPUT_ONLY];
}
Original file line number Diff line number Diff line change
Expand Up @@ -149,4 +149,4 @@ message AdminUser {

// Family name of the admin user.
string family_name = 3;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ message Customer {
// embargoes, we require a region and zip code. You must provide valid
// addresses for every customer. To set the customer's language, use the
// Customer-level language code.
google.type.PostalAddress org_postal_address = 3 [(google.api.field_behavior) = REQUIRED];
google.type.PostalAddress org_postal_address = 3
[(google.api.field_behavior) = REQUIRED];

// Primary contact info.
ContactInfo primary_contact_info = 4;
Expand All @@ -62,10 +63,12 @@ message Customer {
string domain = 6 [(google.api.field_behavior) = REQUIRED];

// Output only. Time when the customer was created.
google.protobuf.Timestamp create_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 7
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Time when the customer was updated.
google.protobuf.Timestamp update_time = 8 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp update_time = 8
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The customer's Cloud Identity ID if the customer has a Cloud
// Identity resource.
Expand All @@ -78,7 +81,8 @@ message Customer {

// Output only. Cloud Identity information for the customer.
// Populated only if a Cloud Identity account exists for this customer.
CloudIdentityInfo cloud_identity_info = 12 [(google.api.field_behavior) = OUTPUT_ONLY];
CloudIdentityInfo cloud_identity_info = 12
[(google.api.field_behavior) = OUTPUT_ONLY];

// Cloud Identity ID of the customer's channel partner.
// Populated only if a channel partner exists for this customer.
Expand Down Expand Up @@ -107,4 +111,4 @@ message ContactInfo {

// The customer account's contact phone number.
string phone = 7;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ message Entitlement {
SUSPENDED = 5;
}

// Suspension reason for an entitlement if [provisioning_state][google.cloud.channel.v1.Entitlement.provisioning_state] = SUSPENDED.
// Suspension reason for an entitlement if
// [provisioning_state][google.cloud.channel.v1.Entitlement.provisioning_state]
// = SUSPENDED.
enum SuspensionReason {
// Not used.
SUSPENSION_REASON_UNSPECIFIED = 0;
Expand All @@ -74,10 +76,12 @@ message Entitlement {
string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time at which the entitlement is created.
google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp create_time = 5
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time at which the entitlement is updated.
google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp update_time = 6
[(google.api.field_behavior) = OUTPUT_ONLY];

// Required. The offer resource name for which the entitlement is to be
// created. Takes the form: accounts/{account_id}/offers/{offer_id}.
Expand All @@ -93,19 +97,23 @@ message Entitlement {
CommitmentSettings commitment_settings = 12;

// Output only. Current provisioning state of the entitlement.
ProvisioningState provisioning_state = 13 [(google.api.field_behavior) = OUTPUT_ONLY];
ProvisioningState provisioning_state = 13
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Service provisioning details for the entitlement.
ProvisionedService provisioned_service = 16 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Enumerable of all current suspension reasons for an entitlement.
repeated SuspensionReason suspension_reasons = 18 [(google.api.field_behavior) = OUTPUT_ONLY];

// Optional. This purchase order (PO) information is for resellers to use for their
// company tracking usage. If a purchaseOrderId value is given, it appears in
// the API responses and shows up in the invoice. The property accepts up to
// 80 plain text characters. This is only supported for Google Workspace
// entitlements.
ProvisionedService provisioned_service = 16
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Enumerable of all current suspension reasons for an
// entitlement.
repeated SuspensionReason suspension_reasons = 18
[(google.api.field_behavior) = OUTPUT_ONLY];

// Optional. This purchase order (PO) information is for resellers to use for
// their company tracking usage. If a purchaseOrderId value is given, it
// appears in the API responses and shows up in the invoice. The property
// accepts up to 80 plain text characters. This is only supported for Google
// Workspace entitlements.
string purchase_order_id = 19 [(google.api.field_behavior) = OPTIONAL];

// Output only. Settings for trial offers.
Expand Down Expand Up @@ -136,42 +144,45 @@ message Parameter {
// Value of the parameter.
Value value = 2;

// Output only. Specifies whether this parameter is allowed to be changed. For example, for
// a Google Workspace Business Starter entitlement in commitment plan,
// num_units is editable when entitlement is active.
// Output only. Specifies whether this parameter is allowed to be changed. For
// example, for a Google Workspace Business Starter entitlement in commitment
// plan, num_units is editable when entitlement is active.
bool editable = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
}

// Association links that an entitlement has to other entitlements.
message AssociationInfo {
// The name of the base entitlement, for which this entitlement is an add-on.
string base_entitlement = 1 [(google.api.resource_reference) = {
type: "cloudchannel.googleapis.com/Entitlement"
}];
type: "cloudchannel.googleapis.com/Entitlement"
}];
}

// Service provisioned for an entitlement.
message ProvisionedService {
// Output only. Provisioning ID of the entitlement. For Google Workspace, this is the
// underlying Subscription ID. For Google Cloud Platform, this is the
// Output only. Provisioning ID of the entitlement. For Google Workspace, this
// is the underlying Subscription ID. For Google Cloud Platform, this is the
// Billing Account ID of the billing subaccount."
string provisioning_id = 1 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The product pertaining to the provisioning resource as specified in the
// Offer.
// Output only. The product pertaining to the provisioning resource as
// specified in the Offer.
string product_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The SKU pertaining to the provisioning resource as specified in the Offer.
// Output only. The SKU pertaining to the provisioning resource as specified
// in the Offer.
string sku_id = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
}

// Commitment settings for commitment-based offers.
message CommitmentSettings {
// Output only. Commitment start timestamp.
google.protobuf.Timestamp start_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp start_time = 1
[(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. Commitment end timestamp.
google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 2
[(google.api.field_behavior) = OUTPUT_ONLY];

// Optional. Renewal settings applicable for a commitment-based Offer.
RenewalSettings renewal_settings = 4 [(google.api.field_behavior) = OPTIONAL];
Expand Down Expand Up @@ -218,7 +229,8 @@ message TransferableSku {
// The SKU pertaining to the provisioning resource as specified in the Offer.
Sku sku = 11;

// Optional. The customer to transfer has an entitlement with the populated legacy SKU.
// Optional. The customer to transfer has an entitlement with the populated
// legacy SKU.
Sku legacy_sku = 12 [(google.api.field_behavior) = OPTIONAL];
}

Expand Down Expand Up @@ -247,4 +259,4 @@ message TransferEligibility {

// Specified the reason for ineligibility.
Reason ineligibility_reason = 3;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ enum PeriodType {
}

// Represents an offer made to resellers for purchase.
// An offer is associated with a [Sku][google.cloud.channel.v1.Sku], has a plan for payment, a price, and
// defines the constraints for buying.
// An offer is associated with a [Sku][google.cloud.channel.v1.Sku], has a plan
// for payment, a price, and defines the constraints for buying.
message Offer {
option (google.api.resource) = {
type: "cloudchannel.googleapis.com/Offer"
Expand Down Expand Up @@ -156,7 +156,8 @@ message Offer {
google.protobuf.Timestamp start_time = 7;

// Output only. End of the Offer validity time.
google.protobuf.Timestamp end_time = 8 [(google.api.field_behavior) = OUTPUT_ONLY];
google.protobuf.Timestamp end_time = 8
[(google.api.field_behavior) = OUTPUT_ONLY];

// Parameters required to use current Offer to purchase.
repeated ParameterDefinition parameter_definitions = 9;
Expand Down Expand Up @@ -326,4 +327,4 @@ message Period {

// Period Type.
PeriodType period_type = 2;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ option java_multiple_files = true;
option java_outer_classname = "OperationsProto";
option java_package = "com.google.cloud.channel.v1";

// Provides contextual information about a [google.longrunning.Operation][google.longrunning.Operation].
// Provides contextual information about a
// [google.longrunning.Operation][google.longrunning.Operation].
message OperationMetadata {
// RPCs that return a Long Running Operation.
enum OperationType {
Expand Down Expand Up @@ -64,4 +65,4 @@ message OperationMetadata {

// The RPC that initiated this Long Running Operation.
OperationType operation_type = 1;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,4 @@ message Media {

// Type of the media.
MediaType type = 3;
}
}
Loading