Skip to content

Commit ce59650

Browse files
fix: add prefix to Zone and Region import (scaleway#1802)
Co-authored-by: Jonathan R. <[email protected]>
1 parent 84a9ec5 commit ce59650

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+666
-632
lines changed

packages/clients/src/api/baremetal/v1/api.gen.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
validatePathParam,
88
waitForResource,
99
} from '../../../bridge'
10-
import type { WaitForOptions, Zone } from '../../../bridge'
10+
import type { Zone as ScwZone, WaitForOptions } from '../../../bridge'
1111
import { SERVER_TRANSIENT_STATUSES } from './content.gen'
1212
import {
1313
marshalAddOptionServerRequest,
@@ -104,7 +104,7 @@ const jsonContentHeaders = {
104104
*/
105105
export class API extends ParentAPI {
106106
/** Lists the available zones of the API. */
107-
public static readonly LOCALITIES: Zone[] = [
107+
public static readonly LOCALITIES: ScwZone[] = [
108108
'fr-par-1',
109109
'fr-par-2',
110110
'nl-ams-1',
@@ -698,7 +698,7 @@ export class API extends ParentAPI {
698698
/** Elastic Metal - Private Network API. */
699699
export class PrivateNetworkAPI extends ParentAPI {
700700
/** Lists the available zones of the API. */
701-
public static readonly LOCALITIES: Zone[] = ['fr-par-2']
701+
public static readonly LOCALITIES: ScwZone[] = ['fr-par-2']
702702

703703
/**
704704
* Add a server to a Private Network.

packages/clients/src/api/baremetal/v1/types.gen.ts

+33-33
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// This file was automatically generated. DO NOT EDIT.
22
// If you have any remark or suggestion do not hesitate to open an issue.
3-
import type { Money, TimeSeries, Zone } from '../../../bridge'
3+
import type { Money, Zone as ScwZone, TimeSeries } from '../../../bridge'
44

55
export type IPReverseStatus = 'unknown' | 'pending' | 'active' | 'error'
66

@@ -585,7 +585,7 @@ export interface Server {
585585
/** Boot type of the server. */
586586
bootType: ServerBootType
587587
/** Zone in which is the server located. */
588-
zone: Zone
588+
zone: ScwZone
589589
/** Configuration of the installation. */
590590
install?: ServerInstall
591591
/** Status of server ping. */
@@ -609,7 +609,7 @@ export interface Setting {
609609

610610
export type AddOptionServerRequest = {
611611
/** Zone to target. If none is passed will use default zone from the config. */
612-
zone?: Zone
612+
zone?: ScwZone
613613
/** ID of the server. */
614614
serverId: string
615615
/** ID of the option to add. */
@@ -640,7 +640,7 @@ export interface BMCAccess {
640640

641641
export type CreateServerRequest = {
642642
/** Zone to target. If none is passed will use default zone from the config. */
643-
zone?: Zone
643+
zone?: ScwZone
644644
/** Offer ID of the new server. */
645645
offerId: string
646646
/**
@@ -674,7 +674,7 @@ export type CreateServerRequest = {
674674

675675
export type DeleteOptionServerRequest = {
676676
/** Zone to target. If none is passed will use default zone from the config. */
677-
zone?: Zone
677+
zone?: ScwZone
678678
/** ID of the server. */
679679
serverId: string
680680
/** ID of the option to delete. */
@@ -683,21 +683,21 @@ export type DeleteOptionServerRequest = {
683683

684684
export type DeleteServerRequest = {
685685
/** Zone to target. If none is passed will use default zone from the config. */
686-
zone?: Zone
686+
zone?: ScwZone
687687
/** ID of the server to delete. */
688688
serverId: string
689689
}
690690

691691
export type GetBMCAccessRequest = {
692692
/** Zone to target. If none is passed will use default zone from the config. */
693-
zone?: Zone
693+
zone?: ScwZone
694694
/** ID of the server. */
695695
serverId: string
696696
}
697697

698698
export type GetDefaultPartitioningSchemaRequest = {
699699
/** Zone to target. If none is passed will use default zone from the config. */
700-
zone?: Zone
700+
zone?: ScwZone
701701
/** ID of the offer. */
702702
offerId: string
703703
/** ID of the OS. */
@@ -706,28 +706,28 @@ export type GetDefaultPartitioningSchemaRequest = {
706706

707707
export type GetOSRequest = {
708708
/** Zone to target. If none is passed will use default zone from the config. */
709-
zone?: Zone
709+
zone?: ScwZone
710710
/** ID of the OS. */
711711
osId: string
712712
}
713713

714714
export type GetOfferRequest = {
715715
/** Zone to target. If none is passed will use default zone from the config. */
716-
zone?: Zone
716+
zone?: ScwZone
717717
/** ID of the researched Offer. */
718718
offerId: string
719719
}
720720

721721
export type GetOptionRequest = {
722722
/** Zone to target. If none is passed will use default zone from the config. */
723-
zone?: Zone
723+
zone?: ScwZone
724724
/** ID of the option. */
725725
optionId: string
726726
}
727727

728728
export type GetServerMetricsRequest = {
729729
/** Zone to target. If none is passed will use default zone from the config. */
730-
zone?: Zone
730+
zone?: ScwZone
731731
/** Server ID to get the metrics. */
732732
serverId: string
733733
}
@@ -739,14 +739,14 @@ export interface GetServerMetricsResponse {
739739

740740
export type GetServerRequest = {
741741
/** Zone to target. If none is passed will use default zone from the config. */
742-
zone?: Zone
742+
zone?: ScwZone
743743
/** ID of the server. */
744744
serverId: string
745745
}
746746

747747
export type InstallServerRequest = {
748748
/** Zone to target. If none is passed will use default zone from the config. */
749-
zone?: Zone
749+
zone?: ScwZone
750750
/** Server ID to install. */
751751
serverId: string
752752
/** ID of the OS to installation on the server. */
@@ -769,7 +769,7 @@ export type InstallServerRequest = {
769769

770770
export type ListOSRequest = {
771771
/** Zone to target. If none is passed will use default zone from the config. */
772-
zone?: Zone
772+
zone?: ScwZone
773773
/** Page number. */
774774
page?: number
775775
/** Number of OS per page. */
@@ -787,7 +787,7 @@ export interface ListOSResponse {
787787

788788
export type ListOffersRequest = {
789789
/** Zone to target. If none is passed will use default zone from the config. */
790-
zone?: Zone
790+
zone?: ScwZone
791791
/** Page number. */
792792
page?: number
793793
/** Number of offers per page. */
@@ -807,7 +807,7 @@ export interface ListOffersResponse {
807807

808808
export type ListOptionsRequest = {
809809
/** Zone to target. If none is passed will use default zone from the config. */
810-
zone?: Zone
810+
zone?: ScwZone
811811
/** Page number. */
812812
page?: number
813813
/** Number of options per page. */
@@ -827,7 +827,7 @@ export interface ListOptionsResponse {
827827

828828
export type ListServerEventsRequest = {
829829
/** Zone to target. If none is passed will use default zone from the config. */
830-
zone?: Zone
830+
zone?: ScwZone
831831
/** ID of the server events searched. */
832832
serverId: string
833833
/** Page number. */
@@ -852,7 +852,7 @@ export interface ListServerPrivateNetworksResponse {
852852

853853
export type ListServersRequest = {
854854
/** Zone to target. If none is passed will use default zone from the config. */
855-
zone?: Zone
855+
zone?: ScwZone
856856
/** Page number. */
857857
page?: number
858858
/** Number of servers per page. */
@@ -882,7 +882,7 @@ export interface ListServersResponse {
882882

883883
export type ListSettingsRequest = {
884884
/** Zone to target. If none is passed will use default zone from the config. */
885-
zone?: Zone
885+
zone?: ScwZone
886886
/** Page number. */
887887
page?: number
888888
/** Set the maximum list size. */
@@ -902,7 +902,7 @@ export interface ListSettingsResponse {
902902

903903
export type PrivateNetworkApiAddServerPrivateNetworkRequest = {
904904
/** Zone to target. If none is passed will use default zone from the config. */
905-
zone?: Zone
905+
zone?: ScwZone
906906
/** The ID of the server. */
907907
serverId: string
908908
/** The ID of the Private Network. */
@@ -911,7 +911,7 @@ export type PrivateNetworkApiAddServerPrivateNetworkRequest = {
911911

912912
export type PrivateNetworkApiDeleteServerPrivateNetworkRequest = {
913913
/** Zone to target. If none is passed will use default zone from the config. */
914-
zone?: Zone
914+
zone?: ScwZone
915915
/** The ID of the server. */
916916
serverId: string
917917
/** The ID of the Private Network. */
@@ -920,7 +920,7 @@ export type PrivateNetworkApiDeleteServerPrivateNetworkRequest = {
920920

921921
export type PrivateNetworkApiListServerPrivateNetworksRequest = {
922922
/** Zone to target. If none is passed will use default zone from the config. */
923-
zone?: Zone
923+
zone?: ScwZone
924924
/** The sort order for the returned Private Networks. */
925925
orderBy?: ListServerPrivateNetworksRequestOrderBy
926926
/** The page number for the returned Private Networks. */
@@ -939,7 +939,7 @@ export type PrivateNetworkApiListServerPrivateNetworksRequest = {
939939

940940
export type PrivateNetworkApiSetServerPrivateNetworksRequest = {
941941
/** Zone to target. If none is passed will use default zone from the config. */
942-
zone?: Zone
942+
zone?: ScwZone
943943
/** The ID of the server. */
944944
serverId: string
945945
/** The IDs of the Private Networks. */
@@ -948,7 +948,7 @@ export type PrivateNetworkApiSetServerPrivateNetworksRequest = {
948948

949949
export type RebootServerRequest = {
950950
/** Zone to target. If none is passed will use default zone from the config. */
951-
zone?: Zone
951+
zone?: ScwZone
952952
/** ID of the server to reboot. */
953953
serverId: string
954954
/** The type of boot. */
@@ -961,7 +961,7 @@ export interface SetServerPrivateNetworksResponse {
961961

962962
export type StartBMCAccessRequest = {
963963
/** Zone to target. If none is passed will use default zone from the config. */
964-
zone?: Zone
964+
zone?: ScwZone
965965
/** ID of the server. */
966966
serverId: string
967967
/** The IP authorized to connect to the server. */
@@ -970,7 +970,7 @@ export type StartBMCAccessRequest = {
970970

971971
export type StartServerRequest = {
972972
/** Zone to target. If none is passed will use default zone from the config. */
973-
zone?: Zone
973+
zone?: ScwZone
974974
/** ID of the server to start. */
975975
serverId: string
976976
/** The type of boot. */
@@ -979,21 +979,21 @@ export type StartServerRequest = {
979979

980980
export type StopBMCAccessRequest = {
981981
/** Zone to target. If none is passed will use default zone from the config. */
982-
zone?: Zone
982+
zone?: ScwZone
983983
/** ID of the server. */
984984
serverId: string
985985
}
986986

987987
export type StopServerRequest = {
988988
/** Zone to target. If none is passed will use default zone from the config. */
989-
zone?: Zone
989+
zone?: ScwZone
990990
/** ID of the server to stop. */
991991
serverId: string
992992
}
993993

994994
export type UpdateIPRequest = {
995995
/** Zone to target. If none is passed will use default zone from the config. */
996-
zone?: Zone
996+
zone?: ScwZone
997997
/** ID of the server. */
998998
serverId: string
999999
/** ID of the IP to update. */
@@ -1004,7 +1004,7 @@ export type UpdateIPRequest = {
10041004

10051005
export type UpdateServerRequest = {
10061006
/** Zone to target. If none is passed will use default zone from the config. */
1007-
zone?: Zone
1007+
zone?: ScwZone
10081008
/** ID of the server to update. */
10091009
serverId: string
10101010
/** Name of the server (≠hostname), not updated if null. */
@@ -1020,7 +1020,7 @@ export type UpdateServerRequest = {
10201020

10211021
export type UpdateSettingRequest = {
10221022
/** Zone to target. If none is passed will use default zone from the config. */
1023-
zone?: Zone
1023+
zone?: ScwZone
10241024
/** ID of the setting. */
10251025
settingId: string
10261026
/** Defines whether the setting is enabled. */
@@ -1029,7 +1029,7 @@ export type UpdateSettingRequest = {
10291029

10301030
export type ValidatePartitioningSchemaRequest = {
10311031
/** Zone to target. If none is passed will use default zone from the config. */
1032-
zone?: Zone
1032+
zone?: ScwZone
10331033
/** Partitioning schema. */
10341034
partitioningSchema?: Schema
10351035
/** Offer ID of the server. */

packages/clients/src/api/baremetal/v3/api.gen.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
urlParams,
77
validatePathParam,
88
} from '../../../bridge'
9-
import type { Zone } from '../../../bridge'
9+
import type { Zone as ScwZone } from '../../../bridge'
1010
import {
1111
marshalPrivateNetworkApiAddServerPrivateNetworkRequest,
1212
marshalPrivateNetworkApiSetServerPrivateNetworksRequest,
@@ -31,7 +31,7 @@ const jsonContentHeaders = {
3131
/** Elastic Metal - Private Networks API. */
3232
export class PrivateNetworkAPI extends ParentAPI {
3333
/** Lists the available zones of the API. */
34-
public static readonly LOCALITIES: Zone[] = [
34+
public static readonly LOCALITIES: ScwZone[] = [
3535
'fr-par-1',
3636
'fr-par-2',
3737
'nl-ams-1',

packages/clients/src/api/baremetal/v3/types.gen.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// This file was automatically generated. DO NOT EDIT.
22
// If you have any remark or suggestion do not hesitate to open an issue.
3-
import type { Zone } from '../../../bridge'
3+
import type { Zone as ScwZone } from '../../../bridge'
44

55
export type ListServerPrivateNetworksRequestOrderBy =
66
| 'created_at_asc'
@@ -44,7 +44,7 @@ export interface ListServerPrivateNetworksResponse {
4444

4545
export type PrivateNetworkApiAddServerPrivateNetworkRequest = {
4646
/** Zone to target. If none is passed will use default zone from the config. */
47-
zone?: Zone
47+
zone?: ScwZone
4848
/** UUID of the server. */
4949
serverId: string
5050
/** UUID of the Private Network. */
@@ -55,7 +55,7 @@ export type PrivateNetworkApiAddServerPrivateNetworkRequest = {
5555

5656
export type PrivateNetworkApiDeleteServerPrivateNetworkRequest = {
5757
/** Zone to target. If none is passed will use default zone from the config. */
58-
zone?: Zone
58+
zone?: ScwZone
5959
/** UUID of the server. */
6060
serverId: string
6161
/** UUID of the Private Network. */
@@ -64,7 +64,7 @@ export type PrivateNetworkApiDeleteServerPrivateNetworkRequest = {
6464

6565
export type PrivateNetworkApiListServerPrivateNetworksRequest = {
6666
/** Zone to target. If none is passed will use default zone from the config. */
67-
zone?: Zone
67+
zone?: ScwZone
6868
/** Sort order for the returned Private Networks. */
6969
orderBy?: ListServerPrivateNetworksRequestOrderBy
7070
/** Page number for the returned Private Networks. */
@@ -85,7 +85,7 @@ export type PrivateNetworkApiListServerPrivateNetworksRequest = {
8585

8686
export type PrivateNetworkApiSetServerPrivateNetworksRequest = {
8787
/** Zone to target. If none is passed will use default zone from the config. */
88-
zone?: Zone
88+
zone?: ScwZone
8989
/** UUID of the server. */
9090
serverId: string
9191
/**

packages/clients/src/api/block/v1alpha1/api.gen.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
validatePathParam,
88
waitForResource,
99
} from '../../../bridge'
10-
import type { WaitForOptions, Zone } from '../../../bridge'
10+
import type { Zone as ScwZone, WaitForOptions } from '../../../bridge'
1111
import {
1212
SNAPSHOT_TRANSIENT_STATUSES,
1313
VOLUME_TRANSIENT_STATUSES,
@@ -59,7 +59,7 @@ const jsonContentHeaders = {
5959
*/
6060
export class API extends ParentAPI {
6161
/** Lists the available zones of the API. */
62-
public static readonly LOCALITIES: Zone[] = [
62+
public static readonly LOCALITIES: ScwZone[] = [
6363
'fr-par-1',
6464
'fr-par-2',
6565
'fr-par-3',

0 commit comments

Comments
 (0)