syntax = "proto3";

package subscription;

import "google/protobuf/any.proto";

service SubscriptionService {
  rpc CreateSubscription(SubscriptionData) returns (SubResponseMessage);
};


message SubResponseMessage {

    message Customer_details {
        string email = 1;
        google.protobuf.Any phone = 2;
    }

    string id = 1;
    uint32 amount_subtotal = 2;
    uint32 amount_total = 3;
    string cancel_url = 4;
    string currency = 5;
    Customer_details customer_details = 6;
    string mode = 7;
    string status = 8;
    string success_url = 9;
    string url = 10;
    string message = 11;
    bool failed = 12;
    string service_id = 13;
}

message SubscriptionData {
  string subscription = 1;
  string email = 2;
  string phone = 3;
  string customer_cx_id = 4;
  string name = 5;
}