Skip to content
Open
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
358 changes: 329 additions & 29 deletions api/pb/v1/oracle.pb.go

Large diffs are not rendered by default.

33 changes: 33 additions & 0 deletions api/pb/v1/oracle.proto
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,39 @@ message GetClaimRequest {
string claim_id = 1; // Unique identifier of the claim to fetch
}

message UploadInvoiceRequest {
string file_content = 1;
string location = 2;
string bucket_name = 3;
}

message UploadInvoiceResponse {
string invoice_id = 1;
string state = 2;

oneof result {
common.v1.Exception exception = 3;
}
}

message ProcessInvoiceRequest {
string invoice_id = 1; // The invoice ID created by UploadInvoice
}

message ProcessInvoiceResponse {
string invoice_id = 1;
string state = 2;

oneof result {
common.v1.Exception exception = 3;
}
}

// message UploadInvoiceResult {
// string invoice_id = 1;
// string state = 2;
// }

// Response containing the requested claim.
message GetClaimResponse {
oneof result {
Expand Down
60 changes: 36 additions & 24 deletions api/srvpb/v1/oracle.pb.go

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

154 changes: 154 additions & 0 deletions api/srvpb/v1/oracle.pb.gw.go

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

16 changes: 16 additions & 0 deletions api/srvpb/v1/oracle.proto
Original file line number Diff line number Diff line change
Expand Up @@ -121,4 +121,20 @@ service SandboxService {
option (google.api.http) = {get: "/v1/sandbox/claim/{claim_id}"};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {tags: "Service"};
}

rpc UploadInvoice(pb.v1.UploadInvoiceRequest) returns (pb.v1.UploadInvoiceResponse) {
option (google.api.http) = {
post: "/v1/sandbox/UploadInvoice"
body: "*"
};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {tags: "Service"};
}

rpc ProcessInvoice(pb.v1.ProcessInvoiceRequest) returns (pb.v1.ProcessInvoiceResponse) {
option (google.api.http) = {
post: "/v1/sandbox/ProcessInvoice"
body: "*"
};
option (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation) = {tags: "Service"};
}
}
Loading
Loading