Skip to content

Commit

Permalink
update types from api specs
Browse files Browse the repository at this point in the history
  • Loading branch information
JanST123 committed Jan 10, 2023
1 parent 269c3fa commit bd7ce59
Show file tree
Hide file tree
Showing 10 changed files with 109 additions and 1 deletion.
Binary file modified apiversion.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/Specs/models/AccessKeyCreate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export type AccessKeyCreate = {
*/
comment?: string;
/**
* Which User UUID the access key will be created
* If a user_uuid is sent along with the request, a user-specific key will get created. If no user_uuid is sent along a user with write-access to the contract will still only create a user-specific key for themselves while a user with admin-access to the contract will create a contract-level admin key.
*/
user_uuid?: string;
}
19 changes: 19 additions & 0 deletions src/Specs/models/ServerCreate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,25 @@ export type ServerCreate = {
auto_recovery?: string;
/**
* Specifies the hardware settings for the virtual machine.
*
* Note: hardware_profile and hardware_profile_config parameters can't be used at the same time.
*
*/
hardware_profile?: 'default' | 'nested' | 'legacy' | 'cisco_csr' | 'sophos_utm' | 'f5_bigip' | 'q35';
/**
* Specifies the custom hardware settings for the virtual machine.
*
* Note: hardware_profile and hardware_profile_config parameters can't be used at the same time.
*
*/
hardware_profile_config?: {
machinetype?: 'i440fx' | 'q35_bios' | 'q35_uefi',
storage_device?: 'ide' | 'sata' | 'virtio_scsi' | 'virtio_block',
usb_controller?: 'nec_xhci' | 'piix3_uhci',
nested_virtualization?: boolean,
hyperv_extensions?: boolean,
network_model?: 'e1000' | 'e1000e' | 'virtio' | 'vmxnet3',
serial_interface?: boolean,
server_renice?: boolean,
};
}
19 changes: 19 additions & 0 deletions src/Specs/models/ServerUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,25 @@ export type ServerUpdate = {
auto_recovery?: boolean;
/**
* Specifies the hardware settings for the virtual machine.
*
* Note: hardware_profile and hardware_profile_config parameters can't be used at the same time.
*
*/
hardware_profile?: 'default' | 'nested' | 'legacy' | 'cisco_csr' | 'sophos_utm' | 'f5_bigip' | 'q35';
/**
* Specifies the custom hardware settings for the virtual machine.
*
* Note: hardware_profile and hardware_profile_config parameters can't be used at the same time.
*
*/
hardware_profile_config?: {
machinetype?: 'i440fx' | 'q35_bios' | 'q35_uefi',
storage_device?: 'ide' | 'sata' | 'virtio_scsi' | 'virtio_block',
usb_controller?: 'nec_xhci' | 'piix3_uhci',
nested_virtualization?: boolean,
hyperv_extensions?: boolean,
network_model?: 'e1000' | 'e1000e' | 'virtio' | 'vmxnet3',
serial_interface?: boolean,
server_renice?: boolean,
};
}
4 changes: 4 additions & 0 deletions src/Specs/models/Template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ export type Template = {
* Status indicates the status of the object.
*/
status?: string;
/**
* Indicates if the template can be used by other users
*/
published?: boolean;
/**
* The operating system installed in the template.
*/
Expand Down
4 changes: 4 additions & 0 deletions src/Specs/models/TemplateUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ export type TemplateUpdate = {
* The human-readable name of the object. It supports the full UTF-8 character set, with a maximum of 64 characters.
*/
name?: string;
/**
* Allow/forbid other user to use this template. Correct access rights are required to make the request with this key
*/
published?: boolean;
/**
* List of labels.
*/
Expand Down
28 changes: 28 additions & 0 deletions src/Specs/schemas/$ServerCreate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,33 @@ export const $ServerCreate = {
hardware_profile: {
type: 'Enum',
},
hardware_profile_config: {
properties: {
machinetype: {
type: 'Enum',
},
storage_device: {
type: 'Enum',
},
usb_controller: {
type: 'Enum',
},
nested_virtualization: {
type: 'boolean',
},
hyperv_extensions: {
type: 'boolean',
},
network_model: {
type: 'Enum',
},
serial_interface: {
type: 'boolean',
},
server_renice: {
type: 'boolean',
},
},
},
},
};
28 changes: 28 additions & 0 deletions src/Specs/schemas/$ServerUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,33 @@ export const $ServerUpdate = {
hardware_profile: {
type: 'Enum',
},
hardware_profile_config: {
properties: {
machinetype: {
type: 'Enum',
},
storage_device: {
type: 'Enum',
},
usb_controller: {
type: 'Enum',
},
nested_virtualization: {
type: 'boolean',
},
hyperv_extensions: {
type: 'boolean',
},
network_model: {
type: 'Enum',
},
serial_interface: {
type: 'boolean',
},
server_renice: {
type: 'boolean',
},
},
},
},
};
3 changes: 3 additions & 0 deletions src/Specs/schemas/$Template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ export const $Template = {
status: {
type: 'string',
},
published: {
type: 'boolean',
},
ostype: {
type: 'string',
},
Expand Down
3 changes: 3 additions & 0 deletions src/Specs/schemas/$TemplateUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ export const $TemplateUpdate = {
name: {
type: 'string',
},
published: {
type: 'boolean',
},
labels: {
type: 'array',
contains: {
Expand Down

0 comments on commit bd7ce59

Please sign in to comment.