Skip to content

Commit f92c7e7

Browse files
authored
Merge pull request #24 from imagekit-developer/stainless/release
Release SDK updates
2 parents 5f35dfa + 5be896c commit f92c7e7

1 file changed

Lines changed: 100 additions & 51 deletions

File tree

file.go

Lines changed: 100 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,8 @@ type Metadata struct {
369369
// The video codec used in the video (only for video).
370370
VideoCodec string `json:"videoCodec"`
371371
// The width of the image or video in pixels.
372-
Width int64 `json:"width"`
372+
Width int64 `json:"width"`
373+
ExtraFields map[string]any `json:"" api:"extrafields"`
373374
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
374375
JSON struct {
375376
AudioCodec respjson.Field
@@ -408,7 +409,8 @@ type MetadataExif struct {
408409
Interoperability MetadataExifInteroperability `json:"interoperability"`
409410
Makernote map[string]any `json:"makernote"`
410411
// Object containing Thumbnail information.
411-
Thumbnail MetadataExifThumbnail `json:"thumbnail"`
412+
Thumbnail MetadataExifThumbnail `json:"thumbnail"`
413+
ExtraFields map[string]any `json:"" api:"extrafields"`
412414
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
413415
JSON struct {
414416
Exif respjson.Field
@@ -430,35 +432,45 @@ func (r *MetadataExif) UnmarshalJSON(data []byte) error {
430432

431433
// Object containing Exif details.
432434
type MetadataExifExif struct {
433-
ApertureValue float64 `json:"ApertureValue"`
434-
ColorSpace int64 `json:"ColorSpace"`
435-
CreateDate string `json:"CreateDate"`
436-
CustomRendered int64 `json:"CustomRendered"`
437-
DateTimeOriginal string `json:"DateTimeOriginal"`
438-
ExifImageHeight int64 `json:"ExifImageHeight"`
439-
ExifImageWidth int64 `json:"ExifImageWidth"`
440-
ExifVersion string `json:"ExifVersion"`
441-
ExposureCompensation float64 `json:"ExposureCompensation"`
442-
ExposureMode int64 `json:"ExposureMode"`
443-
ExposureProgram int64 `json:"ExposureProgram"`
444-
ExposureTime float64 `json:"ExposureTime"`
445-
Flash int64 `json:"Flash"`
446-
FlashpixVersion string `json:"FlashpixVersion"`
447-
FNumber float64 `json:"FNumber"`
448-
FocalLength int64 `json:"FocalLength"`
449-
FocalPlaneResolutionUnit int64 `json:"FocalPlaneResolutionUnit"`
450-
FocalPlaneXResolution float64 `json:"FocalPlaneXResolution"`
451-
FocalPlaneYResolution float64 `json:"FocalPlaneYResolution"`
452-
InteropOffset int64 `json:"InteropOffset"`
453-
ISO int64 `json:"ISO"`
454-
MeteringMode int64 `json:"MeteringMode"`
455-
SceneCaptureType int64 `json:"SceneCaptureType"`
456-
ShutterSpeedValue float64 `json:"ShutterSpeedValue"`
457-
SubSecTime string `json:"SubSecTime"`
458-
WhiteBalance int64 `json:"WhiteBalance"`
435+
ApertureValue float64 `json:"ApertureValue"`
436+
BrightnessValue float64 `json:"BrightnessValue"`
437+
ColorSpace int64 `json:"ColorSpace"`
438+
CreateDate string `json:"CreateDate"`
439+
CustomRendered int64 `json:"CustomRendered"`
440+
DateTimeOriginal string `json:"DateTimeOriginal"`
441+
ExifImageHeight int64 `json:"ExifImageHeight"`
442+
ExifImageWidth int64 `json:"ExifImageWidth"`
443+
ExifVersion string `json:"ExifVersion"`
444+
ExposureCompensation float64 `json:"ExposureCompensation"`
445+
ExposureMode int64 `json:"ExposureMode"`
446+
ExposureProgram int64 `json:"ExposureProgram"`
447+
ExposureTime float64 `json:"ExposureTime"`
448+
Flash int64 `json:"Flash"`
449+
FlashpixVersion string `json:"FlashpixVersion"`
450+
FNumber float64 `json:"FNumber"`
451+
FocalLength float64 `json:"FocalLength"`
452+
FocalLengthIn35mmFormat int64 `json:"FocalLengthIn35mmFormat"`
453+
FocalPlaneResolutionUnit int64 `json:"FocalPlaneResolutionUnit"`
454+
FocalPlaneXResolution float64 `json:"FocalPlaneXResolution"`
455+
FocalPlaneYResolution float64 `json:"FocalPlaneYResolution"`
456+
InteropOffset int64 `json:"InteropOffset"`
457+
ISO int64 `json:"ISO"`
458+
LensModel string `json:"LensModel"`
459+
LightSource int64 `json:"LightSource"`
460+
MaxApertureValue float64 `json:"MaxApertureValue"`
461+
MeteringMode int64 `json:"MeteringMode"`
462+
SceneCaptureType int64 `json:"SceneCaptureType"`
463+
SceneType string `json:"SceneType"`
464+
SensingMethod int64 `json:"SensingMethod"`
465+
ShutterSpeedValue float64 `json:"ShutterSpeedValue"`
466+
SubSecTime string `json:"SubSecTime"`
467+
UserComment string `json:"UserComment"`
468+
WhiteBalance int64 `json:"WhiteBalance"`
469+
ExtraFields map[string]any `json:"" api:"extrafields"`
459470
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
460471
JSON struct {
461472
ApertureValue respjson.Field
473+
BrightnessValue respjson.Field
462474
ColorSpace respjson.Field
463475
CreateDate respjson.Field
464476
CustomRendered respjson.Field
@@ -474,15 +486,22 @@ type MetadataExifExif struct {
474486
FlashpixVersion respjson.Field
475487
FNumber respjson.Field
476488
FocalLength respjson.Field
489+
FocalLengthIn35mmFormat respjson.Field
477490
FocalPlaneResolutionUnit respjson.Field
478491
FocalPlaneXResolution respjson.Field
479492
FocalPlaneYResolution respjson.Field
480493
InteropOffset respjson.Field
481494
ISO respjson.Field
495+
LensModel respjson.Field
496+
LightSource respjson.Field
497+
MaxApertureValue respjson.Field
482498
MeteringMode respjson.Field
483499
SceneCaptureType respjson.Field
500+
SceneType respjson.Field
501+
SensingMethod respjson.Field
484502
ShutterSpeedValue respjson.Field
485503
SubSecTime respjson.Field
504+
UserComment respjson.Field
486505
WhiteBalance respjson.Field
487506
ExtraFields map[string]respjson.Field
488507
raw string
@@ -497,12 +516,33 @@ func (r *MetadataExifExif) UnmarshalJSON(data []byte) error {
497516

498517
// Object containing GPS information.
499518
type MetadataExifGps struct {
500-
GpsVersionID []int64 `json:"GPSVersionID"`
519+
GpsAltitude float64 `json:"GPSAltitude"`
520+
GpsAltitudeRef int64 `json:"GPSAltitudeRef"`
521+
GpsDateStamp string `json:"GPSDateStamp"`
522+
GpsImgDirection float64 `json:"GPSImgDirection"`
523+
GpsImgDirectionRef string `json:"GPSImgDirectionRef"`
524+
GpsLatitude []float64 `json:"GPSLatitude"`
525+
GpsLatitudeRef string `json:"GPSLatitudeRef"`
526+
GpsLongitude []float64 `json:"GPSLongitude"`
527+
GpsLongitudeRef string `json:"GPSLongitudeRef"`
528+
GpsTimeStamp []float64 `json:"GPSTimeStamp"`
529+
GpsVersionID []int64 `json:"GPSVersionID"`
530+
ExtraFields map[string]any `json:"" api:"extrafields"`
501531
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
502532
JSON struct {
503-
GpsVersionID respjson.Field
504-
ExtraFields map[string]respjson.Field
505-
raw string
533+
GpsAltitude respjson.Field
534+
GpsAltitudeRef respjson.Field
535+
GpsDateStamp respjson.Field
536+
GpsImgDirection respjson.Field
537+
GpsImgDirectionRef respjson.Field
538+
GpsLatitude respjson.Field
539+
GpsLatitudeRef respjson.Field
540+
GpsLongitude respjson.Field
541+
GpsLongitudeRef respjson.Field
542+
GpsTimeStamp respjson.Field
543+
GpsVersionID respjson.Field
544+
ExtraFields map[string]respjson.Field
545+
raw string
506546
} `json:"-"`
507547
}
508548

@@ -514,21 +554,28 @@ func (r *MetadataExifGps) UnmarshalJSON(data []byte) error {
514554

515555
// Object containing EXIF image information.
516556
type MetadataExifImage struct {
517-
ExifOffset int64 `json:"ExifOffset"`
518-
GpsInfo int64 `json:"GPSInfo"`
519-
Make string `json:"Make"`
520-
Model string `json:"Model"`
521-
ModifyDate string `json:"ModifyDate"`
522-
Orientation int64 `json:"Orientation"`
523-
ResolutionUnit int64 `json:"ResolutionUnit"`
524-
Software string `json:"Software"`
525-
XResolution int64 `json:"XResolution"`
526-
YCbCrPositioning int64 `json:"YCbCrPositioning"`
527-
YResolution int64 `json:"YResolution"`
557+
Artist string `json:"Artist"`
558+
Copyright string `json:"Copyright"`
559+
ExifOffset int64 `json:"ExifOffset"`
560+
GpsInfo int64 `json:"GPSInfo"`
561+
ImageDescription string `json:"ImageDescription"`
562+
Make string `json:"Make"`
563+
Model string `json:"Model"`
564+
ModifyDate string `json:"ModifyDate"`
565+
Orientation int64 `json:"Orientation"`
566+
ResolutionUnit int64 `json:"ResolutionUnit"`
567+
Software string `json:"Software"`
568+
XResolution float64 `json:"XResolution"`
569+
YCbCrPositioning int64 `json:"YCbCrPositioning"`
570+
YResolution float64 `json:"YResolution"`
571+
ExtraFields map[string]any `json:"" api:"extrafields"`
528572
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
529573
JSON struct {
574+
Artist respjson.Field
575+
Copyright respjson.Field
530576
ExifOffset respjson.Field
531577
GpsInfo respjson.Field
578+
ImageDescription respjson.Field
532579
Make respjson.Field
533580
Model respjson.Field
534581
ModifyDate respjson.Field
@@ -551,8 +598,9 @@ func (r *MetadataExifImage) UnmarshalJSON(data []byte) error {
551598

552599
// JSON object.
553600
type MetadataExifInteroperability struct {
554-
InteropIndex string `json:"InteropIndex"`
555-
InteropVersion string `json:"InteropVersion"`
601+
InteropIndex string `json:"InteropIndex"`
602+
InteropVersion string `json:"InteropVersion"`
603+
ExtraFields map[string]any `json:"" api:"extrafields"`
556604
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
557605
JSON struct {
558606
InteropIndex respjson.Field
@@ -570,12 +618,13 @@ func (r *MetadataExifInteroperability) UnmarshalJSON(data []byte) error {
570618

571619
// Object containing Thumbnail information.
572620
type MetadataExifThumbnail struct {
573-
Compression int64 `json:"Compression"`
574-
ResolutionUnit int64 `json:"ResolutionUnit"`
575-
ThumbnailLength int64 `json:"ThumbnailLength"`
576-
ThumbnailOffset int64 `json:"ThumbnailOffset"`
577-
XResolution int64 `json:"XResolution"`
578-
YResolution int64 `json:"YResolution"`
621+
Compression int64 `json:"Compression"`
622+
ResolutionUnit int64 `json:"ResolutionUnit"`
623+
ThumbnailLength int64 `json:"ThumbnailLength"`
624+
ThumbnailOffset int64 `json:"ThumbnailOffset"`
625+
XResolution float64 `json:"XResolution"`
626+
YResolution float64 `json:"YResolution"`
627+
ExtraFields map[string]any `json:"" api:"extrafields"`
579628
// JSON contains metadata for fields, check presence with [respjson.Field.Valid].
580629
JSON struct {
581630
Compression respjson.Field

0 commit comments

Comments
 (0)