allow specifying conversion resolution, drop explicit dpi

This commit is contained in:
2026-03-27 13:51:56 -07:00
parent 5f68aa5567
commit 5923bff155
14 changed files with 398 additions and 94 deletions
+139 -42
View File
@@ -137,6 +137,65 @@ func (ConversionPhase) EnumDescriptor() ([]byte, []int) {
return file_officeconvertapi_v1_conversion_proto_rawDescGZIP(), []int{1}
}
// ConversionResolution represents preset output quality targets.
type ConversionResolution int32
const (
ConversionResolution_CONVERSION_RESOLUTION_UNSPECIFIED ConversionResolution = 0
ConversionResolution_CONVERSION_RESOLUTION_SD ConversionResolution = 1
ConversionResolution_CONVERSION_RESOLUTION_HD ConversionResolution = 2
ConversionResolution_CONVERSION_RESOLUTION_FHD ConversionResolution = 3
ConversionResolution_CONVERSION_RESOLUTION_QHD ConversionResolution = 4
ConversionResolution_CONVERSION_RESOLUTION_UHD ConversionResolution = 5
)
// Enum value maps for ConversionResolution.
var (
ConversionResolution_name = map[int32]string{
0: "CONVERSION_RESOLUTION_UNSPECIFIED",
1: "CONVERSION_RESOLUTION_SD",
2: "CONVERSION_RESOLUTION_HD",
3: "CONVERSION_RESOLUTION_FHD",
4: "CONVERSION_RESOLUTION_QHD",
5: "CONVERSION_RESOLUTION_UHD",
}
ConversionResolution_value = map[string]int32{
"CONVERSION_RESOLUTION_UNSPECIFIED": 0,
"CONVERSION_RESOLUTION_SD": 1,
"CONVERSION_RESOLUTION_HD": 2,
"CONVERSION_RESOLUTION_FHD": 3,
"CONVERSION_RESOLUTION_QHD": 4,
"CONVERSION_RESOLUTION_UHD": 5,
}
)
func (x ConversionResolution) Enum() *ConversionResolution {
p := new(ConversionResolution)
*p = x
return p
}
func (x ConversionResolution) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (ConversionResolution) Descriptor() protoreflect.EnumDescriptor {
return file_officeconvertapi_v1_conversion_proto_enumTypes[2].Descriptor()
}
func (ConversionResolution) Type() protoreflect.EnumType {
return &file_officeconvertapi_v1_conversion_proto_enumTypes[2]
}
func (x ConversionResolution) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use ConversionResolution.Descriptor instead.
func (ConversionResolution) EnumDescriptor() ([]byte, []int) {
return file_officeconvertapi_v1_conversion_proto_rawDescGZIP(), []int{2}
}
// Slide contains extracted notes and the rendered image URL for one slide.
type Slide struct {
state protoimpl.MessageState `protogen:"open.v1"`
@@ -205,6 +264,8 @@ type SlideDeck struct {
SourceFilename string `protobuf:"bytes,2,opt,name=source_filename,json=sourceFilename,proto3" json:"source_filename,omitempty"`
Slides []*Slide `protobuf:"bytes,3,rep,name=slides,proto3" json:"slides,omitempty"`
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
Width int32 `protobuf:"varint,5,opt,name=width,proto3" json:"width,omitempty"`
Height int32 `protobuf:"varint,6,opt,name=height,proto3" json:"height,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -267,10 +328,25 @@ func (x *SlideDeck) GetCreatedAt() *timestamppb.Timestamp {
return nil
}
func (x *SlideDeck) GetWidth() int32 {
if x != nil {
return x.Width
}
return 0
}
func (x *SlideDeck) GetHeight() int32 {
if x != nil {
return x.Height
}
return 0
}
// CreateConversionRequest starts a conversion session.
type CreateConversionRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
SourceFilename string `protobuf:"bytes,1,opt,name=source_filename,json=sourceFilename,proto3" json:"source_filename,omitempty"`
Resolution ConversionResolution `protobuf:"varint,2,opt,name=resolution,proto3,enum=officeconvertapi.v1.ConversionResolution" json:"resolution,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
@@ -312,6 +388,13 @@ func (x *CreateConversionRequest) GetSourceFilename() string {
return ""
}
func (x *CreateConversionRequest) GetResolution() ConversionResolution {
if x != nil {
return x.Resolution
}
return ConversionResolution_CONVERSION_RESOLUTION_UNSPECIFIED
}
// CreateConversionResponse returns upload details for the session.
type CreateConversionResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
@@ -822,15 +905,20 @@ const file_officeconvertapi_v1_conversion_proto_rawDesc = "" +
"\x05index\x18\x01 \x01(\x05R\x05index\x12\x1f\n" +
"\vnotes_plain\x18\x02 \x01(\tR\n" +
"notesPlain\x12\x1b\n" +
"\timage_url\x18\x03 \x01(\tR\bimageUrl\"\xc8\x01\n" +
"\timage_url\x18\x03 \x01(\tR\bimageUrl\"\xf6\x01\n" +
"\tSlideDeck\x12#\n" +
"\rconversion_id\x18\x01 \x01(\tR\fconversionId\x12'\n" +
"\x0fsource_filename\x18\x02 \x01(\tR\x0esourceFilename\x122\n" +
"\x06slides\x18\x03 \x03(\v2\x1a.officeconvertapi.v1.SlideR\x06slides\x129\n" +
"\n" +
"created_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\"B\n" +
"created_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x14\n" +
"\x05width\x18\x05 \x01(\x05R\x05width\x12\x16\n" +
"\x06height\x18\x06 \x01(\x05R\x06height\"\x8d\x01\n" +
"\x17CreateConversionRequest\x12'\n" +
"\x0fsource_filename\x18\x01 \x01(\tR\x0esourceFilename\"\xea\x01\n" +
"\x0fsource_filename\x18\x01 \x01(\tR\x0esourceFilename\x12I\n" +
"\n" +
"resolution\x18\x02 \x01(\x0e2).officeconvertapi.v1.ConversionResolutionR\n" +
"resolution\"\xea\x01\n" +
"\x18CreateConversionResponse\x12#\n" +
"\rconversion_id\x18\x01 \x01(\tR\fconversionId\x12#\n" +
"\rupload_bucket\x18\x02 \x01(\tR\fuploadBucket\x12*\n" +
@@ -877,7 +965,14 @@ const file_officeconvertapi_v1_conversion_proto_rawDesc = "" +
"!CONVERSION_PHASE_EXTRACTING_NOTES\x10\x02\x12 \n" +
"\x1cCONVERSION_PHASE_PPTX_TO_PDF\x10\x03\x12\"\n" +
"\x1eCONVERSION_PHASE_PDF_TO_IMAGES\x10\x04\x12&\n" +
"\"CONVERSION_PHASE_UPLOADING_RESULTS\x10\x052\xcc\x04\n" +
"\"CONVERSION_PHASE_UPLOADING_RESULTS\x10\x05*\xd6\x01\n" +
"\x14ConversionResolution\x12%\n" +
"!CONVERSION_RESOLUTION_UNSPECIFIED\x10\x00\x12\x1c\n" +
"\x18CONVERSION_RESOLUTION_SD\x10\x01\x12\x1c\n" +
"\x18CONVERSION_RESOLUTION_HD\x10\x02\x12\x1d\n" +
"\x19CONVERSION_RESOLUTION_FHD\x10\x03\x12\x1d\n" +
"\x19CONVERSION_RESOLUTION_QHD\x10\x04\x12\x1d\n" +
"\x19CONVERSION_RESOLUTION_UHD\x10\x052\xcc\x04\n" +
"\x11ConversionService\x12q\n" +
"\x10CreateConversion\x12,.officeconvertapi.v1.CreateConversionRequest\x1a-.officeconvertapi.v1.CreateConversionResponse\"\x00\x12n\n" +
"\x0fStartConversion\x12+.officeconvertapi.v1.StartConversionRequest\x1a,.officeconvertapi.v1.StartConversionResponse\"\x00\x12z\n" +
@@ -897,49 +992,51 @@ func file_officeconvertapi_v1_conversion_proto_rawDescGZIP() []byte {
return file_officeconvertapi_v1_conversion_proto_rawDescData
}
var file_officeconvertapi_v1_conversion_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
var file_officeconvertapi_v1_conversion_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
var file_officeconvertapi_v1_conversion_proto_msgTypes = make([]protoimpl.MessageInfo, 12)
var file_officeconvertapi_v1_conversion_proto_goTypes = []any{
(ConversionStatus)(0), // 0: officeconvertapi.v1.ConversionStatus
(ConversionPhase)(0), // 1: officeconvertapi.v1.ConversionPhase
(*Slide)(nil), // 2: officeconvertapi.v1.Slide
(*SlideDeck)(nil), // 3: officeconvertapi.v1.SlideDeck
(*CreateConversionRequest)(nil), // 4: officeconvertapi.v1.CreateConversionRequest
(*CreateConversionResponse)(nil), // 5: officeconvertapi.v1.CreateConversionResponse
(*StartConversionRequest)(nil), // 6: officeconvertapi.v1.StartConversionRequest
(*StartConversionResponse)(nil), // 7: officeconvertapi.v1.StartConversionResponse
(*GetConversionStatusRequest)(nil), // 8: officeconvertapi.v1.GetConversionStatusRequest
(*GetConversionStatusResponse)(nil), // 9: officeconvertapi.v1.GetConversionStatusResponse
(*GetSlideDeckRequest)(nil), // 10: officeconvertapi.v1.GetSlideDeckRequest
(*GetSlideDeckResponse)(nil), // 11: officeconvertapi.v1.GetSlideDeckResponse
(*DeleteConversionRequest)(nil), // 12: officeconvertapi.v1.DeleteConversionRequest
(*DeleteConversionResponse)(nil), // 13: officeconvertapi.v1.DeleteConversionResponse
(*timestamppb.Timestamp)(nil), // 14: google.protobuf.Timestamp
(ConversionResolution)(0), // 2: officeconvertapi.v1.ConversionResolution
(*Slide)(nil), // 3: officeconvertapi.v1.Slide
(*SlideDeck)(nil), // 4: officeconvertapi.v1.SlideDeck
(*CreateConversionRequest)(nil), // 5: officeconvertapi.v1.CreateConversionRequest
(*CreateConversionResponse)(nil), // 6: officeconvertapi.v1.CreateConversionResponse
(*StartConversionRequest)(nil), // 7: officeconvertapi.v1.StartConversionRequest
(*StartConversionResponse)(nil), // 8: officeconvertapi.v1.StartConversionResponse
(*GetConversionStatusRequest)(nil), // 9: officeconvertapi.v1.GetConversionStatusRequest
(*GetConversionStatusResponse)(nil), // 10: officeconvertapi.v1.GetConversionStatusResponse
(*GetSlideDeckRequest)(nil), // 11: officeconvertapi.v1.GetSlideDeckRequest
(*GetSlideDeckResponse)(nil), // 12: officeconvertapi.v1.GetSlideDeckResponse
(*DeleteConversionRequest)(nil), // 13: officeconvertapi.v1.DeleteConversionRequest
(*DeleteConversionResponse)(nil), // 14: officeconvertapi.v1.DeleteConversionResponse
(*timestamppb.Timestamp)(nil), // 15: google.protobuf.Timestamp
}
var file_officeconvertapi_v1_conversion_proto_depIdxs = []int32{
2, // 0: officeconvertapi.v1.SlideDeck.slides:type_name -> officeconvertapi.v1.Slide
14, // 1: officeconvertapi.v1.SlideDeck.created_at:type_name -> google.protobuf.Timestamp
14, // 2: officeconvertapi.v1.CreateConversionResponse.expires_at:type_name -> google.protobuf.Timestamp
0, // 3: officeconvertapi.v1.StartConversionResponse.status:type_name -> officeconvertapi.v1.ConversionStatus
0, // 4: officeconvertapi.v1.GetConversionStatusResponse.status:type_name -> officeconvertapi.v1.ConversionStatus
14, // 5: officeconvertapi.v1.GetConversionStatusResponse.updated_at:type_name -> google.protobuf.Timestamp
1, // 6: officeconvertapi.v1.GetConversionStatusResponse.phase:type_name -> officeconvertapi.v1.ConversionPhase
3, // 7: officeconvertapi.v1.GetSlideDeckResponse.slide_deck:type_name -> officeconvertapi.v1.SlideDeck
4, // 8: officeconvertapi.v1.ConversionService.CreateConversion:input_type -> officeconvertapi.v1.CreateConversionRequest
6, // 9: officeconvertapi.v1.ConversionService.StartConversion:input_type -> officeconvertapi.v1.StartConversionRequest
8, // 10: officeconvertapi.v1.ConversionService.GetConversionStatus:input_type -> officeconvertapi.v1.GetConversionStatusRequest
10, // 11: officeconvertapi.v1.ConversionService.GetSlideDeck:input_type -> officeconvertapi.v1.GetSlideDeckRequest
12, // 12: officeconvertapi.v1.ConversionService.DeleteConversion:input_type -> officeconvertapi.v1.DeleteConversionRequest
5, // 13: officeconvertapi.v1.ConversionService.CreateConversion:output_type -> officeconvertapi.v1.CreateConversionResponse
7, // 14: officeconvertapi.v1.ConversionService.StartConversion:output_type -> officeconvertapi.v1.StartConversionResponse
9, // 15: officeconvertapi.v1.ConversionService.GetConversionStatus:output_type -> officeconvertapi.v1.GetConversionStatusResponse
11, // 16: officeconvertapi.v1.ConversionService.GetSlideDeck:output_type -> officeconvertapi.v1.GetSlideDeckResponse
13, // 17: officeconvertapi.v1.ConversionService.DeleteConversion:output_type -> officeconvertapi.v1.DeleteConversionResponse
13, // [13:18] is the sub-list for method output_type
8, // [8:13] is the sub-list for method input_type
8, // [8:8] is the sub-list for extension type_name
8, // [8:8] is the sub-list for extension extendee
0, // [0:8] is the sub-list for field type_name
3, // 0: officeconvertapi.v1.SlideDeck.slides:type_name -> officeconvertapi.v1.Slide
15, // 1: officeconvertapi.v1.SlideDeck.created_at:type_name -> google.protobuf.Timestamp
2, // 2: officeconvertapi.v1.CreateConversionRequest.resolution:type_name -> officeconvertapi.v1.ConversionResolution
15, // 3: officeconvertapi.v1.CreateConversionResponse.expires_at:type_name -> google.protobuf.Timestamp
0, // 4: officeconvertapi.v1.StartConversionResponse.status:type_name -> officeconvertapi.v1.ConversionStatus
0, // 5: officeconvertapi.v1.GetConversionStatusResponse.status:type_name -> officeconvertapi.v1.ConversionStatus
15, // 6: officeconvertapi.v1.GetConversionStatusResponse.updated_at:type_name -> google.protobuf.Timestamp
1, // 7: officeconvertapi.v1.GetConversionStatusResponse.phase:type_name -> officeconvertapi.v1.ConversionPhase
4, // 8: officeconvertapi.v1.GetSlideDeckResponse.slide_deck:type_name -> officeconvertapi.v1.SlideDeck
5, // 9: officeconvertapi.v1.ConversionService.CreateConversion:input_type -> officeconvertapi.v1.CreateConversionRequest
7, // 10: officeconvertapi.v1.ConversionService.StartConversion:input_type -> officeconvertapi.v1.StartConversionRequest
9, // 11: officeconvertapi.v1.ConversionService.GetConversionStatus:input_type -> officeconvertapi.v1.GetConversionStatusRequest
11, // 12: officeconvertapi.v1.ConversionService.GetSlideDeck:input_type -> officeconvertapi.v1.GetSlideDeckRequest
13, // 13: officeconvertapi.v1.ConversionService.DeleteConversion:input_type -> officeconvertapi.v1.DeleteConversionRequest
6, // 14: officeconvertapi.v1.ConversionService.CreateConversion:output_type -> officeconvertapi.v1.CreateConversionResponse
8, // 15: officeconvertapi.v1.ConversionService.StartConversion:output_type -> officeconvertapi.v1.StartConversionResponse
10, // 16: officeconvertapi.v1.ConversionService.GetConversionStatus:output_type -> officeconvertapi.v1.GetConversionStatusResponse
12, // 17: officeconvertapi.v1.ConversionService.GetSlideDeck:output_type -> officeconvertapi.v1.GetSlideDeckResponse
14, // 18: officeconvertapi.v1.ConversionService.DeleteConversion:output_type -> officeconvertapi.v1.DeleteConversionResponse
14, // [14:19] is the sub-list for method output_type
9, // [9:14] is the sub-list for method input_type
9, // [9:9] is the sub-list for extension type_name
9, // [9:9] is the sub-list for extension extendee
0, // [0:9] is the sub-list for field type_name
}
func init() { file_officeconvertapi_v1_conversion_proto_init() }
@@ -952,7 +1049,7 @@ func file_officeconvertapi_v1_conversion_proto_init() {
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_officeconvertapi_v1_conversion_proto_rawDesc), len(file_officeconvertapi_v1_conversion_proto_rawDesc)),
NumEnums: 2,
NumEnums: 3,
NumMessages: 12,
NumExtensions: 0,
NumServices: 1,
@@ -25,7 +25,7 @@ _sym_db = _symbol_database.Default()
from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n$officeconvertapi/v1/conversion.proto\x12\x13officeconvertapi.v1\x1a\x1fgoogle/protobuf/timestamp.proto\"[\n\x05Slide\x12\x14\n\x05index\x18\x01 \x01(\x05R\x05index\x12\x1f\n\x0bnotes_plain\x18\x02 \x01(\tR\nnotesPlain\x12\x1b\n\timage_url\x18\x03 \x01(\tR\x08imageUrl\"\xc8\x01\n\tSlideDeck\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12\'\n\x0fsource_filename\x18\x02 \x01(\tR\x0esourceFilename\x12\x32\n\x06slides\x18\x03 \x03(\x0b\x32\x1a.officeconvertapi.v1.SlideR\x06slides\x12\x39\n\ncreated_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\"B\n\x17\x43reateConversionRequest\x12\'\n\x0fsource_filename\x18\x01 \x01(\tR\x0esourceFilename\"\xea\x01\n\x18\x43reateConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12#\n\rupload_bucket\x18\x02 \x01(\tR\x0cuploadBucket\x12*\n\x11upload_object_key\x18\x03 \x01(\tR\x0fuploadObjectKey\x12\x1d\n\nupload_url\x18\x04 \x01(\tR\tuploadUrl\x12\x39\n\nexpires_at\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\texpiresAt\"=\n\x16StartConversionRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"}\n\x17StartConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12=\n\x06status\x18\x02 \x01(\x0e\x32%.officeconvertapi.v1.ConversionStatusR\x06status\"A\n\x1aGetConversionStatusRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"\xeb\x02\n\x1bGetConversionStatusResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12=\n\x06status\x18\x02 \x01(\x0e\x32%.officeconvertapi.v1.ConversionStatusR\x06status\x12#\n\rerror_message\x18\x03 \x01(\tR\x0c\x65rrorMessage\x12\x39\n\nupdated_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tupdatedAt\x12:\n\x05phase\x18\x05 \x01(\x0e\x32$.officeconvertapi.v1.ConversionPhaseR\x05phase\x12)\n\x10\x63urrent_progress\x18\x06 \x01(\x05R\x0f\x63urrentProgress\x12!\n\x0cmax_progress\x18\x07 \x01(\x05R\x0bmaxProgress\":\n\x13GetSlideDeckRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"U\n\x14GetSlideDeckResponse\x12=\n\nslide_deck\x18\x01 \x01(\x0b\x32\x1e.officeconvertapi.v1.SlideDeckR\tslideDeck\">\n\x17\x44\x65leteConversionRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"Y\n\x18\x44\x65leteConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12\x18\n\x07\x64\x65leted\x18\x02 \x01(\x08R\x07\x64\x65leted*\xb2\x01\n\x10\x43onversionStatus\x12!\n\x1d\x43ONVERSION_STATUS_UNSPECIFIED\x10\x00\x12\x1d\n\x19\x43ONVERSION_STATUS_PENDING\x10\x01\x12\x1d\n\x19\x43ONVERSION_STATUS_RUNNING\x10\x02\x12\x1f\n\x1b\x43ONVERSION_STATUS_SUCCEEDED\x10\x03\x12\x1c\n\x18\x43ONVERSION_STATUS_FAILED\x10\x04*\xe7\x01\n\x0f\x43onversionPhase\x12 \n\x1c\x43ONVERSION_PHASE_UNSPECIFIED\x10\x00\x12\x1d\n\x19\x43ONVERSION_PHASE_INACTIVE\x10\x01\x12%\n!CONVERSION_PHASE_EXTRACTING_NOTES\x10\x02\x12 \n\x1c\x43ONVERSION_PHASE_PPTX_TO_PDF\x10\x03\x12\"\n\x1e\x43ONVERSION_PHASE_PDF_TO_IMAGES\x10\x04\x12&\n\"CONVERSION_PHASE_UPLOADING_RESULTS\x10\x05\x32\xcc\x04\n\x11\x43onversionService\x12q\n\x10\x43reateConversion\x12,.officeconvertapi.v1.CreateConversionRequest\x1a-.officeconvertapi.v1.CreateConversionResponse\"\x00\x12n\n\x0fStartConversion\x12+.officeconvertapi.v1.StartConversionRequest\x1a,.officeconvertapi.v1.StartConversionResponse\"\x00\x12z\n\x13GetConversionStatus\x12/.officeconvertapi.v1.GetConversionStatusRequest\x1a\x30.officeconvertapi.v1.GetConversionStatusResponse\"\x00\x12\x65\n\x0cGetSlideDeck\x12(.officeconvertapi.v1.GetSlideDeckRequest\x1a).officeconvertapi.v1.GetSlideDeckResponse\"\x00\x12q\n\x10\x44\x65leteConversion\x12,.officeconvertapi.v1.DeleteConversionRequest\x1a-.officeconvertapi.v1.DeleteConversionResponse\"\x00\x42LZJgithub.com/end/officeconvert/gen/go/officeconvertapi/v1;officeconvertapiv1b\x06proto3')
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n$officeconvertapi/v1/conversion.proto\x12\x13officeconvertapi.v1\x1a\x1fgoogle/protobuf/timestamp.proto\"[\n\x05Slide\x12\x14\n\x05index\x18\x01 \x01(\x05R\x05index\x12\x1f\n\x0bnotes_plain\x18\x02 \x01(\tR\nnotesPlain\x12\x1b\n\timage_url\x18\x03 \x01(\tR\x08imageUrl\"\xf6\x01\n\tSlideDeck\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12\'\n\x0fsource_filename\x18\x02 \x01(\tR\x0esourceFilename\x12\x32\n\x06slides\x18\x03 \x03(\x0b\x32\x1a.officeconvertapi.v1.SlideR\x06slides\x12\x39\n\ncreated_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x14\n\x05width\x18\x05 \x01(\x05R\x05width\x12\x16\n\x06height\x18\x06 \x01(\x05R\x06height\"\x8d\x01\n\x17\x43reateConversionRequest\x12\'\n\x0fsource_filename\x18\x01 \x01(\tR\x0esourceFilename\x12I\n\nresolution\x18\x02 \x01(\x0e\x32).officeconvertapi.v1.ConversionResolutionR\nresolution\"\xea\x01\n\x18\x43reateConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12#\n\rupload_bucket\x18\x02 \x01(\tR\x0cuploadBucket\x12*\n\x11upload_object_key\x18\x03 \x01(\tR\x0fuploadObjectKey\x12\x1d\n\nupload_url\x18\x04 \x01(\tR\tuploadUrl\x12\x39\n\nexpires_at\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\texpiresAt\"=\n\x16StartConversionRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"}\n\x17StartConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12=\n\x06status\x18\x02 \x01(\x0e\x32%.officeconvertapi.v1.ConversionStatusR\x06status\"A\n\x1aGetConversionStatusRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"\xeb\x02\n\x1bGetConversionStatusResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12=\n\x06status\x18\x02 \x01(\x0e\x32%.officeconvertapi.v1.ConversionStatusR\x06status\x12#\n\rerror_message\x18\x03 \x01(\tR\x0c\x65rrorMessage\x12\x39\n\nupdated_at\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tupdatedAt\x12:\n\x05phase\x18\x05 \x01(\x0e\x32$.officeconvertapi.v1.ConversionPhaseR\x05phase\x12)\n\x10\x63urrent_progress\x18\x06 \x01(\x05R\x0f\x63urrentProgress\x12!\n\x0cmax_progress\x18\x07 \x01(\x05R\x0bmaxProgress\":\n\x13GetSlideDeckRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"U\n\x14GetSlideDeckResponse\x12=\n\nslide_deck\x18\x01 \x01(\x0b\x32\x1e.officeconvertapi.v1.SlideDeckR\tslideDeck\">\n\x17\x44\x65leteConversionRequest\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\"Y\n\x18\x44\x65leteConversionResponse\x12#\n\rconversion_id\x18\x01 \x01(\tR\x0c\x63onversionId\x12\x18\n\x07\x64\x65leted\x18\x02 \x01(\x08R\x07\x64\x65leted*\xb2\x01\n\x10\x43onversionStatus\x12!\n\x1d\x43ONVERSION_STATUS_UNSPECIFIED\x10\x00\x12\x1d\n\x19\x43ONVERSION_STATUS_PENDING\x10\x01\x12\x1d\n\x19\x43ONVERSION_STATUS_RUNNING\x10\x02\x12\x1f\n\x1b\x43ONVERSION_STATUS_SUCCEEDED\x10\x03\x12\x1c\n\x18\x43ONVERSION_STATUS_FAILED\x10\x04*\xe7\x01\n\x0f\x43onversionPhase\x12 \n\x1c\x43ONVERSION_PHASE_UNSPECIFIED\x10\x00\x12\x1d\n\x19\x43ONVERSION_PHASE_INACTIVE\x10\x01\x12%\n!CONVERSION_PHASE_EXTRACTING_NOTES\x10\x02\x12 \n\x1c\x43ONVERSION_PHASE_PPTX_TO_PDF\x10\x03\x12\"\n\x1e\x43ONVERSION_PHASE_PDF_TO_IMAGES\x10\x04\x12&\n\"CONVERSION_PHASE_UPLOADING_RESULTS\x10\x05*\xd6\x01\n\x14\x43onversionResolution\x12%\n!CONVERSION_RESOLUTION_UNSPECIFIED\x10\x00\x12\x1c\n\x18\x43ONVERSION_RESOLUTION_SD\x10\x01\x12\x1c\n\x18\x43ONVERSION_RESOLUTION_HD\x10\x02\x12\x1d\n\x19\x43ONVERSION_RESOLUTION_FHD\x10\x03\x12\x1d\n\x19\x43ONVERSION_RESOLUTION_QHD\x10\x04\x12\x1d\n\x19\x43ONVERSION_RESOLUTION_UHD\x10\x05\x32\xcc\x04\n\x11\x43onversionService\x12q\n\x10\x43reateConversion\x12,.officeconvertapi.v1.CreateConversionRequest\x1a-.officeconvertapi.v1.CreateConversionResponse\"\x00\x12n\n\x0fStartConversion\x12+.officeconvertapi.v1.StartConversionRequest\x1a,.officeconvertapi.v1.StartConversionResponse\"\x00\x12z\n\x13GetConversionStatus\x12/.officeconvertapi.v1.GetConversionStatusRequest\x1a\x30.officeconvertapi.v1.GetConversionStatusResponse\"\x00\x12\x65\n\x0cGetSlideDeck\x12(.officeconvertapi.v1.GetSlideDeckRequest\x1a).officeconvertapi.v1.GetSlideDeckResponse\"\x00\x12q\n\x10\x44\x65leteConversion\x12,.officeconvertapi.v1.DeleteConversionRequest\x1a-.officeconvertapi.v1.DeleteConversionResponse\"\x00\x42LZJgithub.com/end/officeconvert/gen/go/officeconvertapi/v1;officeconvertapiv1b\x06proto3')
_globals = globals()
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -33,34 +33,36 @@ _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'officeconvertapi.v1.convers
if not _descriptor._USE_C_DESCRIPTORS:
_globals['DESCRIPTOR']._loaded_options = None
_globals['DESCRIPTOR']._serialized_options = b'ZJgithub.com/end/officeconvert/gen/go/officeconvertapi/v1;officeconvertapiv1'
_globals['_CONVERSIONSTATUS']._serialized_start=1621
_globals['_CONVERSIONSTATUS']._serialized_end=1799
_globals['_CONVERSIONPHASE']._serialized_start=1802
_globals['_CONVERSIONPHASE']._serialized_end=2033
_globals['_CONVERSIONSTATUS']._serialized_start=1743
_globals['_CONVERSIONSTATUS']._serialized_end=1921
_globals['_CONVERSIONPHASE']._serialized_start=1924
_globals['_CONVERSIONPHASE']._serialized_end=2155
_globals['_CONVERSIONRESOLUTION']._serialized_start=2158
_globals['_CONVERSIONRESOLUTION']._serialized_end=2372
_globals['_SLIDE']._serialized_start=94
_globals['_SLIDE']._serialized_end=185
_globals['_SLIDEDECK']._serialized_start=188
_globals['_SLIDEDECK']._serialized_end=388
_globals['_CREATECONVERSIONREQUEST']._serialized_start=390
_globals['_CREATECONVERSIONREQUEST']._serialized_end=456
_globals['_CREATECONVERSIONRESPONSE']._serialized_start=459
_globals['_CREATECONVERSIONRESPONSE']._serialized_end=693
_globals['_STARTCONVERSIONREQUEST']._serialized_start=695
_globals['_STARTCONVERSIONREQUEST']._serialized_end=756
_globals['_STARTCONVERSIONRESPONSE']._serialized_start=758
_globals['_STARTCONVERSIONRESPONSE']._serialized_end=883
_globals['_GETCONVERSIONSTATUSREQUEST']._serialized_start=885
_globals['_GETCONVERSIONSTATUSREQUEST']._serialized_end=950
_globals['_GETCONVERSIONSTATUSRESPONSE']._serialized_start=953
_globals['_GETCONVERSIONSTATUSRESPONSE']._serialized_end=1316
_globals['_GETSLIDEDECKREQUEST']._serialized_start=1318
_globals['_GETSLIDEDECKREQUEST']._serialized_end=1376
_globals['_GETSLIDEDECKRESPONSE']._serialized_start=1378
_globals['_GETSLIDEDECKRESPONSE']._serialized_end=1463
_globals['_DELETECONVERSIONREQUEST']._serialized_start=1465
_globals['_DELETECONVERSIONREQUEST']._serialized_end=1527
_globals['_DELETECONVERSIONRESPONSE']._serialized_start=1529
_globals['_DELETECONVERSIONRESPONSE']._serialized_end=1618
_globals['_CONVERSIONSERVICE']._serialized_start=2036
_globals['_CONVERSIONSERVICE']._serialized_end=2624
_globals['_SLIDEDECK']._serialized_end=434
_globals['_CREATECONVERSIONREQUEST']._serialized_start=437
_globals['_CREATECONVERSIONREQUEST']._serialized_end=578
_globals['_CREATECONVERSIONRESPONSE']._serialized_start=581
_globals['_CREATECONVERSIONRESPONSE']._serialized_end=815
_globals['_STARTCONVERSIONREQUEST']._serialized_start=817
_globals['_STARTCONVERSIONREQUEST']._serialized_end=878
_globals['_STARTCONVERSIONRESPONSE']._serialized_start=880
_globals['_STARTCONVERSIONRESPONSE']._serialized_end=1005
_globals['_GETCONVERSIONSTATUSREQUEST']._serialized_start=1007
_globals['_GETCONVERSIONSTATUSREQUEST']._serialized_end=1072
_globals['_GETCONVERSIONSTATUSRESPONSE']._serialized_start=1075
_globals['_GETCONVERSIONSTATUSRESPONSE']._serialized_end=1438
_globals['_GETSLIDEDECKREQUEST']._serialized_start=1440
_globals['_GETSLIDEDECKREQUEST']._serialized_end=1498
_globals['_GETSLIDEDECKRESPONSE']._serialized_start=1500
_globals['_GETSLIDEDECKRESPONSE']._serialized_end=1585
_globals['_DELETECONVERSIONREQUEST']._serialized_start=1587
_globals['_DELETECONVERSIONREQUEST']._serialized_end=1649
_globals['_DELETECONVERSIONRESPONSE']._serialized_start=1651
_globals['_DELETECONVERSIONRESPONSE']._serialized_end=1740
_globals['_CONVERSIONSERVICE']._serialized_start=2375
_globals['_CONVERSIONSERVICE']._serialized_end=2963
# @@protoc_insertion_point(module_scope)
@@ -26,6 +26,15 @@ class ConversionPhase(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
CONVERSION_PHASE_PPTX_TO_PDF: _ClassVar[ConversionPhase]
CONVERSION_PHASE_PDF_TO_IMAGES: _ClassVar[ConversionPhase]
CONVERSION_PHASE_UPLOADING_RESULTS: _ClassVar[ConversionPhase]
class ConversionResolution(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
__slots__ = ()
CONVERSION_RESOLUTION_UNSPECIFIED: _ClassVar[ConversionResolution]
CONVERSION_RESOLUTION_SD: _ClassVar[ConversionResolution]
CONVERSION_RESOLUTION_HD: _ClassVar[ConversionResolution]
CONVERSION_RESOLUTION_FHD: _ClassVar[ConversionResolution]
CONVERSION_RESOLUTION_QHD: _ClassVar[ConversionResolution]
CONVERSION_RESOLUTION_UHD: _ClassVar[ConversionResolution]
CONVERSION_STATUS_UNSPECIFIED: ConversionStatus
CONVERSION_STATUS_PENDING: ConversionStatus
CONVERSION_STATUS_RUNNING: ConversionStatus
@@ -37,6 +46,12 @@ CONVERSION_PHASE_EXTRACTING_NOTES: ConversionPhase
CONVERSION_PHASE_PPTX_TO_PDF: ConversionPhase
CONVERSION_PHASE_PDF_TO_IMAGES: ConversionPhase
CONVERSION_PHASE_UPLOADING_RESULTS: ConversionPhase
CONVERSION_RESOLUTION_UNSPECIFIED: ConversionResolution
CONVERSION_RESOLUTION_SD: ConversionResolution
CONVERSION_RESOLUTION_HD: ConversionResolution
CONVERSION_RESOLUTION_FHD: ConversionResolution
CONVERSION_RESOLUTION_QHD: ConversionResolution
CONVERSION_RESOLUTION_UHD: ConversionResolution
class Slide(_message.Message):
__slots__ = ("index", "notes_plain", "image_url")
@@ -49,22 +64,28 @@ class Slide(_message.Message):
def __init__(self, index: _Optional[int] = ..., notes_plain: _Optional[str] = ..., image_url: _Optional[str] = ...) -> None: ...
class SlideDeck(_message.Message):
__slots__ = ("conversion_id", "source_filename", "slides", "created_at")
__slots__ = ("conversion_id", "source_filename", "slides", "created_at", "width", "height")
CONVERSION_ID_FIELD_NUMBER: _ClassVar[int]
SOURCE_FILENAME_FIELD_NUMBER: _ClassVar[int]
SLIDES_FIELD_NUMBER: _ClassVar[int]
CREATED_AT_FIELD_NUMBER: _ClassVar[int]
WIDTH_FIELD_NUMBER: _ClassVar[int]
HEIGHT_FIELD_NUMBER: _ClassVar[int]
conversion_id: str
source_filename: str
slides: _containers.RepeatedCompositeFieldContainer[Slide]
created_at: _timestamp_pb2.Timestamp
def __init__(self, conversion_id: _Optional[str] = ..., source_filename: _Optional[str] = ..., slides: _Optional[_Iterable[_Union[Slide, _Mapping]]] = ..., created_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ...
width: int
height: int
def __init__(self, conversion_id: _Optional[str] = ..., source_filename: _Optional[str] = ..., slides: _Optional[_Iterable[_Union[Slide, _Mapping]]] = ..., created_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ..., width: _Optional[int] = ..., height: _Optional[int] = ...) -> None: ...
class CreateConversionRequest(_message.Message):
__slots__ = ("source_filename",)
__slots__ = ("source_filename", "resolution")
SOURCE_FILENAME_FIELD_NUMBER: _ClassVar[int]
RESOLUTION_FIELD_NUMBER: _ClassVar[int]
source_filename: str
def __init__(self, source_filename: _Optional[str] = ...) -> None: ...
resolution: ConversionResolution
def __init__(self, source_filename: _Optional[str] = ..., resolution: _Optional[_Union[ConversionResolution, str]] = ...) -> None: ...
class CreateConversionResponse(_message.Message):
__slots__ = ("conversion_id", "upload_bucket", "upload_object_key", "upload_url", "expires_at")