Drive http reference

Fireback accelerates backend and mobile app development, offering powerful code generation tools and standardized architecture. With seamless backend integration and streamlined workflows, Fireback expedites the creation of robust and scalable apps.

getDrive

drive

Response Dto/Entity: *[]drive.FileEntity

message FileEntity {
    string   name  = 1;
    string   diskPath  = 2;
    int64    size  = 3;
    string   virtualPath  = 4;
    string   uniqueId  = 5; // @tag(gorm:"primarykey;uniqueId;unique;not null;size:100;" yaml:"uniqueId")
    string   type  = 6;

	WorkspaceEntity workspace = 7;    // @tag(gorm:"foreignKey:WorkspaceId;references:UniqueId" json:"-")
	optional string workspaceId = 8;                     // @tag(json:"workspaceId" gorm:"size:100;")

	UserEntity user =9;  // @tag(gorm:"foreignKey:UserId;references:UniqueId" json:"-")
	string userId  = 10; // @tag(json:"userId" gorm:"size:100;")
    optional string visibility = 11; // @tag(yaml:"visibility")
    int64 rank = 15; // @tag(gorm:"type:int;name:rank")
    int64 updated = 16; // @tag(gorm:"autoUpdateTime:nano")
    int64 created = 12; // @tag(gorm:"autoUpdateTime:nano")
    string createdFormatted = 13; // @tag(sql:"-")
    string updatedFormatted = 14; // @tag(sql:"-")
}
export interface FileEntity {
  name: string;
  diskPath: string;
  size: number;
  virtualPath: string;
  /** @tag(gorm:"primarykey;uniqueId;unique;not null;size:100;" yaml:"uniqueId") */
  uniqueId: string;
  type: string;
  /** @tag(gorm:"foreignKey:WorkspaceId;references:UniqueId" json:"-") */
  workspace: WorkspaceEntity | undefined;
  /** @tag(json:"workspaceId" gorm:"size:100;") */
  workspaceId?: string | undefined;
  /** @tag(gorm:"foreignKey:UserId;references:UniqueId" json:"-") */
  user: UserEntity | undefined;
  /** @tag(json:"userId" gorm:"size:100;") */
  userId: string;
  /** @tag(yaml:"visibility") */
  visibility?: string | undefined;
  /** @tag(gorm:"type:int;name:rank") */
  rank: number;
  /** @tag(gorm:"autoUpdateTime:nano") */
  updated: number;
  /** @tag(gorm:"autoUpdateTime:nano") */
  created: number;
  /** @tag(sql:"-") */
  createdFormatted: string;
  /** @tag(sql:"-") */
  updatedFormatted: string;
}

getDriveByUniqueId

drive/:uniqueId

Response Dto/Entity: *drive.FileEntity

message FileEntity {
    string   name  = 1;
    string   diskPath  = 2;
    int64    size  = 3;
    string   virtualPath  = 4;
    string   uniqueId  = 5; // @tag(gorm:"primarykey;uniqueId;unique;not null;size:100;" yaml:"uniqueId")
    string   type  = 6;

	WorkspaceEntity workspace = 7;    // @tag(gorm:"foreignKey:WorkspaceId;references:UniqueId" json:"-")
	optional string workspaceId = 8;                     // @tag(json:"workspaceId" gorm:"size:100;")

	UserEntity user =9;  // @tag(gorm:"foreignKey:UserId;references:UniqueId" json:"-")
	string userId  = 10; // @tag(json:"userId" gorm:"size:100;")
    optional string visibility = 11; // @tag(yaml:"visibility")
    int64 rank = 15; // @tag(gorm:"type:int;name:rank")
    int64 updated = 16; // @tag(gorm:"autoUpdateTime:nano")
    int64 created = 12; // @tag(gorm:"autoUpdateTime:nano")
    string createdFormatted = 13; // @tag(sql:"-")
    string updatedFormatted = 14; // @tag(sql:"-")
}
export interface FileEntity {
  name: string;
  diskPath: string;
  size: number;
  virtualPath: string;
  /** @tag(gorm:"primarykey;uniqueId;unique;not null;size:100;" yaml:"uniqueId") */
  uniqueId: string;
  type: string;
  /** @tag(gorm:"foreignKey:WorkspaceId;references:UniqueId" json:"-") */
  workspace: WorkspaceEntity | undefined;
  /** @tag(json:"workspaceId" gorm:"size:100;") */
  workspaceId?: string | undefined;
  /** @tag(gorm:"foreignKey:UserId;references:UniqueId" json:"-") */
  user: UserEntity | undefined;
  /** @tag(json:"userId" gorm:"size:100;") */
  userId: string;
  /** @tag(yaml:"visibility") */
  visibility?: string | undefined;
  /** @tag(gorm:"type:int;name:rank") */
  rank: number;
  /** @tag(gorm:"autoUpdateTime:nano") */
  updated: number;
  /** @tag(gorm:"autoUpdateTime:nano") */
  created: number;
  /** @tag(sql:"-") */
  createdFormatted: string;
  /** @tag(sql:"-") */
  updatedFormatted: string;
}

Params: :uniqueId