|
@@ -171,6 +171,80 @@ export type AlreadyRefundedError = ErrorResult & {
|
|
|
refundId: Scalars['ID']['output'];
|
|
refundId: Scalars['ID']['output'];
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
+export type ApiKey = Node & {
|
|
|
|
|
+ __typename?: 'ApiKey';
|
|
|
|
|
+ createdAt: Scalars['DateTime']['output'];
|
|
|
|
|
+ customFields?: Maybe<Scalars['JSON']['output']>;
|
|
|
|
|
+ id: Scalars['ID']['output'];
|
|
|
|
|
+ /** Helps you identify unused keys */
|
|
|
|
|
+ lastUsedAt?: Maybe<Scalars['DateTime']['output']>;
|
|
|
|
|
+ /**
|
|
|
|
|
+ * ID by which we can look up the API-Key.
|
|
|
|
|
+ * Also helps you identify keys without leaking the underlying secret API-Key.
|
|
|
|
|
+ */
|
|
|
|
|
+ lookupId: Scalars['String']['output'];
|
|
|
|
|
+ /** A descriptive name so you can remind yourself where the API-Key gets used */
|
|
|
|
|
+ name: Scalars['String']['output'];
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Usually the user who created the ApiKey but could also be used as the basis for
|
|
|
|
|
+ * restricting resolvers to `Permission.Owner` queries for customers for example.
|
|
|
|
|
+ */
|
|
|
|
|
+ owner: User;
|
|
|
|
|
+ translations: Array<ApiKeyTranslation>;
|
|
|
|
|
+ updatedAt: Scalars['DateTime']['output'];
|
|
|
|
|
+ /** This is the underlying User which determines the kind of permissions for this API-Key. */
|
|
|
|
|
+ user: User;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type ApiKeyFilterParameter = {
|
|
|
|
|
+ _and?: InputMaybe<Array<ApiKeyFilterParameter>>;
|
|
|
|
|
+ _or?: InputMaybe<Array<ApiKeyFilterParameter>>;
|
|
|
|
|
+ createdAt?: InputMaybe<DateOperators>;
|
|
|
|
|
+ id?: InputMaybe<IdOperators>;
|
|
|
|
|
+ lastUsedAt?: InputMaybe<DateOperators>;
|
|
|
|
|
+ lookupId?: InputMaybe<StringOperators>;
|
|
|
|
|
+ name?: InputMaybe<StringOperators>;
|
|
|
|
|
+ updatedAt?: InputMaybe<DateOperators>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type ApiKeyList = PaginatedList & {
|
|
|
|
|
+ __typename?: 'ApiKeyList';
|
|
|
|
|
+ items: Array<ApiKey>;
|
|
|
|
|
+ totalItems: Scalars['Int']['output'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type ApiKeyListOptions = {
|
|
|
|
|
+ /** Allows the results to be filtered */
|
|
|
|
|
+ filter?: InputMaybe<ApiKeyFilterParameter>;
|
|
|
|
|
+ /** Specifies whether multiple top-level "filter" fields should be combined with a logical AND or OR operation. Defaults to AND. */
|
|
|
|
|
+ filterOperator?: InputMaybe<LogicalOperator>;
|
|
|
|
|
+ /** Skips the first n results, for use in pagination */
|
|
|
|
|
+ skip?: InputMaybe<Scalars['Int']['input']>;
|
|
|
|
|
+ /** Specifies which properties to sort the results by */
|
|
|
|
|
+ sort?: InputMaybe<ApiKeySortParameter>;
|
|
|
|
|
+ /** Takes n results, for use in pagination */
|
|
|
|
|
+ take?: InputMaybe<Scalars['Int']['input']>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type ApiKeySortParameter = {
|
|
|
|
|
+ createdAt?: InputMaybe<SortOrder>;
|
|
|
|
|
+ id?: InputMaybe<SortOrder>;
|
|
|
|
|
+ lastUsedAt?: InputMaybe<SortOrder>;
|
|
|
|
|
+ lookupId?: InputMaybe<SortOrder>;
|
|
|
|
|
+ name?: InputMaybe<SortOrder>;
|
|
|
|
|
+ updatedAt?: InputMaybe<SortOrder>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type ApiKeyTranslation = Node & {
|
|
|
|
|
+ __typename?: 'ApiKeyTranslation';
|
|
|
|
|
+ createdAt: Scalars['DateTime']['output'];
|
|
|
|
|
+ id: Scalars['ID']['output'];
|
|
|
|
|
+ languageCode: LanguageCode;
|
|
|
|
|
+ /** A descriptive name so you can remind yourself where the API-Key gets used */
|
|
|
|
|
+ name: Scalars['String']['output'];
|
|
|
|
|
+ updatedAt: Scalars['DateTime']['output'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
export type ApplyCouponCodeResult = CouponCodeExpiredError | CouponCodeInvalidError | CouponCodeLimitError | Order;
|
|
export type ApplyCouponCodeResult = CouponCodeExpiredError | CouponCodeInvalidError | CouponCodeLimitError | Order;
|
|
|
|
|
|
|
|
export type Asset = Node & {
|
|
export type Asset = Node & {
|
|
@@ -752,6 +826,35 @@ export type CreateAdministratorInput = {
|
|
|
roleIds: Array<Scalars['ID']['input']>;
|
|
roleIds: Array<Scalars['ID']['input']>;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
+/**
|
|
|
|
|
+ * There is no User ID because you can only create API-Keys for yourself,
|
|
|
|
|
+ * which gets determined by the User who does the request.
|
|
|
|
|
+ */
|
|
|
|
|
+export type CreateApiKeyInput = {
|
|
|
|
|
+ customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Which roles to attach to this ApiKey.
|
|
|
|
|
+ * You may only grant roles which you, yourself have.
|
|
|
|
|
+ */
|
|
|
|
|
+ roleIds: Array<Scalars['ID']['input']>;
|
|
|
|
|
+ translations: Array<CreateApiKeyTranslationInput>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type CreateApiKeyResult = {
|
|
|
|
|
+ __typename?: 'CreateApiKeyResult';
|
|
|
|
|
+ /** The generated API-Key. API-Keys cannot be viewed again after creation! */
|
|
|
|
|
+ apiKey: Scalars['String']['output'];
|
|
|
|
|
+ /** ID of the created ApiKey-Entity */
|
|
|
|
|
+ entityId: Scalars['ID']['output'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type CreateApiKeyTranslationInput = {
|
|
|
|
|
+ customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
|
|
+ languageCode: LanguageCode;
|
|
|
|
|
+ /** A descriptive name so you can remind yourself where the API-Key gets used */
|
|
|
|
|
+ name: Scalars['String']['input'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
export type CreateAssetInput = {
|
|
export type CreateAssetInput = {
|
|
|
customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
file: Scalars['Upload']['input'];
|
|
file: Scalars['Upload']['input'];
|
|
@@ -1358,6 +1461,7 @@ export type CustomFields = {
|
|
|
__typename?: 'CustomFields';
|
|
__typename?: 'CustomFields';
|
|
|
Address: Array<CustomFieldConfig>;
|
|
Address: Array<CustomFieldConfig>;
|
|
|
Administrator: Array<CustomFieldConfig>;
|
|
Administrator: Array<CustomFieldConfig>;
|
|
|
|
|
+ ApiKey: Array<CustomFieldConfig>;
|
|
|
Asset: Array<CustomFieldConfig>;
|
|
Asset: Array<CustomFieldConfig>;
|
|
|
Channel: Array<CustomFieldConfig>;
|
|
Channel: Array<CustomFieldConfig>;
|
|
|
Collection: Array<CustomFieldConfig>;
|
|
Collection: Array<CustomFieldConfig>;
|
|
@@ -2798,6 +2902,12 @@ export type Mutation = {
|
|
|
cancelPayment: CancelPaymentResult;
|
|
cancelPayment: CancelPaymentResult;
|
|
|
/** Create a new Administrator */
|
|
/** Create a new Administrator */
|
|
|
createAdministrator: Administrator;
|
|
createAdministrator: Administrator;
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Generates a new API-Key and attaches it to an Administrator.
|
|
|
|
|
+ * Returns the generated API-Key.
|
|
|
|
|
+ * API-Keys cannot be viewed again after creation.
|
|
|
|
|
+ */
|
|
|
|
|
+ createApiKey: CreateApiKeyResult;
|
|
|
/** Create a new Asset */
|
|
/** Create a new Asset */
|
|
|
createAssets: Array<CreateAssetResult>;
|
|
createAssets: Array<CreateAssetResult>;
|
|
|
/** Create a new Channel */
|
|
/** Create a new Channel */
|
|
@@ -2852,6 +2962,8 @@ export type Mutation = {
|
|
|
deleteAdministrator: DeletionResponse;
|
|
deleteAdministrator: DeletionResponse;
|
|
|
/** Delete multiple Administrators */
|
|
/** Delete multiple Administrators */
|
|
|
deleteAdministrators: Array<DeletionResponse>;
|
|
deleteAdministrators: Array<DeletionResponse>;
|
|
|
|
|
+ /** Deletes API-Keys */
|
|
|
|
|
+ deleteApiKeys: Array<DeletionResponse>;
|
|
|
/** Delete an Asset */
|
|
/** Delete an Asset */
|
|
|
deleteAsset: DeletionResponse;
|
|
deleteAsset: DeletionResponse;
|
|
|
/** Delete multiple Assets */
|
|
/** Delete multiple Assets */
|
|
@@ -2991,6 +3103,12 @@ export type Mutation = {
|
|
|
removeShippingMethodsFromChannel: Array<ShippingMethod>;
|
|
removeShippingMethodsFromChannel: Array<ShippingMethod>;
|
|
|
/** Removes StockLocations from the specified Channel */
|
|
/** Removes StockLocations from the specified Channel */
|
|
|
removeStockLocationsFromChannel: Array<StockLocation>;
|
|
removeStockLocationsFromChannel: Array<StockLocation>;
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Replaces the old with a new API-Key.
|
|
|
|
|
+ * This is a convenience method to invalidate an API-Key without
|
|
|
|
|
+ * deleting the underlying roles and permissions.
|
|
|
|
|
+ */
|
|
|
|
|
+ rotateApiKey: RotateApiKeyResult;
|
|
|
runPendingSearchIndexUpdates: Success;
|
|
runPendingSearchIndexUpdates: Success;
|
|
|
runScheduledTask: Success;
|
|
runScheduledTask: Success;
|
|
|
setCustomerForDraftOrder: SetCustomerForDraftOrderResult;
|
|
setCustomerForDraftOrder: SetCustomerForDraftOrderResult;
|
|
@@ -3022,6 +3140,8 @@ export type Mutation = {
|
|
|
updateActiveAdministrator: Administrator;
|
|
updateActiveAdministrator: Administrator;
|
|
|
/** Update an existing Administrator */
|
|
/** Update an existing Administrator */
|
|
|
updateAdministrator: Administrator;
|
|
updateAdministrator: Administrator;
|
|
|
|
|
+ /** Updates an API-Key */
|
|
|
|
|
+ updateApiKey: ApiKey;
|
|
|
/** Update an existing Asset */
|
|
/** Update an existing Asset */
|
|
|
updateAsset: Asset;
|
|
updateAsset: Asset;
|
|
|
/** Update an existing Channel */
|
|
/** Update an existing Channel */
|
|
@@ -3214,6 +3334,11 @@ export type MutationCreateAdministratorArgs = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+export type MutationCreateApiKeyArgs = {
|
|
|
|
|
+ input: CreateApiKeyInput;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
export type MutationCreateAssetsArgs = {
|
|
export type MutationCreateAssetsArgs = {
|
|
|
input: Array<CreateAssetInput>;
|
|
input: Array<CreateAssetInput>;
|
|
|
};
|
|
};
|
|
@@ -3351,6 +3476,11 @@ export type MutationDeleteAdministratorsArgs = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+export type MutationDeleteApiKeysArgs = {
|
|
|
|
|
+ ids: Array<Scalars['ID']['input']>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
export type MutationDeleteAssetArgs = {
|
|
export type MutationDeleteAssetArgs = {
|
|
|
input: DeleteAssetInput;
|
|
input: DeleteAssetInput;
|
|
|
};
|
|
};
|
|
@@ -3690,6 +3820,11 @@ export type MutationRemoveStockLocationsFromChannelArgs = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+export type MutationRotateApiKeyArgs = {
|
|
|
|
|
+ id: Scalars['ID']['input'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
export type MutationRunScheduledTaskArgs = {
|
|
export type MutationRunScheduledTaskArgs = {
|
|
|
id: Scalars['String']['input'];
|
|
id: Scalars['String']['input'];
|
|
|
};
|
|
};
|
|
@@ -3794,6 +3929,11 @@ export type MutationUpdateAdministratorArgs = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+export type MutationUpdateApiKeyArgs = {
|
|
|
|
|
+ input: UpdateApiKeyInput;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
export type MutationUpdateAssetArgs = {
|
|
export type MutationUpdateAssetArgs = {
|
|
|
input: UpdateAssetInput;
|
|
input: UpdateAssetInput;
|
|
|
};
|
|
};
|
|
@@ -4493,6 +4633,8 @@ export enum Permission {
|
|
|
Authenticated = 'Authenticated',
|
|
Authenticated = 'Authenticated',
|
|
|
/** Grants permission to create Administrator */
|
|
/** Grants permission to create Administrator */
|
|
|
CreateAdministrator = 'CreateAdministrator',
|
|
CreateAdministrator = 'CreateAdministrator',
|
|
|
|
|
+ /** Grants permission to create ApiKey */
|
|
|
|
|
+ CreateApiKey = 'CreateApiKey',
|
|
|
/** Grants permission to create Asset */
|
|
/** Grants permission to create Asset */
|
|
|
CreateAsset = 'CreateAsset',
|
|
CreateAsset = 'CreateAsset',
|
|
|
/** Grants permission to create Products, Facets, Assets, Collections */
|
|
/** Grants permission to create Products, Facets, Assets, Collections */
|
|
@@ -4537,6 +4679,8 @@ export enum Permission {
|
|
|
CreateZone = 'CreateZone',
|
|
CreateZone = 'CreateZone',
|
|
|
/** Grants permission to delete Administrator */
|
|
/** Grants permission to delete Administrator */
|
|
|
DeleteAdministrator = 'DeleteAdministrator',
|
|
DeleteAdministrator = 'DeleteAdministrator',
|
|
|
|
|
+ /** Grants permission to delete ApiKey */
|
|
|
|
|
+ DeleteApiKey = 'DeleteApiKey',
|
|
|
/** Grants permission to delete Asset */
|
|
/** Grants permission to delete Asset */
|
|
|
DeleteAsset = 'DeleteAsset',
|
|
DeleteAsset = 'DeleteAsset',
|
|
|
/** Grants permission to delete Products, Facets, Assets, Collections */
|
|
/** Grants permission to delete Products, Facets, Assets, Collections */
|
|
@@ -4585,6 +4729,8 @@ export enum Permission {
|
|
|
Public = 'Public',
|
|
Public = 'Public',
|
|
|
/** Grants permission to read Administrator */
|
|
/** Grants permission to read Administrator */
|
|
|
ReadAdministrator = 'ReadAdministrator',
|
|
ReadAdministrator = 'ReadAdministrator',
|
|
|
|
|
+ /** Grants permission to read ApiKey */
|
|
|
|
|
+ ReadApiKey = 'ReadApiKey',
|
|
|
/** Grants permission to read Asset */
|
|
/** Grants permission to read Asset */
|
|
|
ReadAsset = 'ReadAsset',
|
|
ReadAsset = 'ReadAsset',
|
|
|
/** Grants permission to read Products, Facets, Assets, Collections */
|
|
/** Grants permission to read Products, Facets, Assets, Collections */
|
|
@@ -4631,6 +4777,8 @@ export enum Permission {
|
|
|
SuperAdmin = 'SuperAdmin',
|
|
SuperAdmin = 'SuperAdmin',
|
|
|
/** Grants permission to update Administrator */
|
|
/** Grants permission to update Administrator */
|
|
|
UpdateAdministrator = 'UpdateAdministrator',
|
|
UpdateAdministrator = 'UpdateAdministrator',
|
|
|
|
|
+ /** Grants permission to update ApiKey */
|
|
|
|
|
+ UpdateApiKey = 'UpdateApiKey',
|
|
|
/** Grants permission to update Asset */
|
|
/** Grants permission to update Asset */
|
|
|
UpdateAsset = 'UpdateAsset',
|
|
UpdateAsset = 'UpdateAsset',
|
|
|
/** Grants permission to update Products, Facets, Assets, Collections */
|
|
/** Grants permission to update Products, Facets, Assets, Collections */
|
|
@@ -5181,6 +5329,8 @@ export type Query = {
|
|
|
activeChannel: Channel;
|
|
activeChannel: Channel;
|
|
|
administrator?: Maybe<Administrator>;
|
|
administrator?: Maybe<Administrator>;
|
|
|
administrators: AdministratorList;
|
|
administrators: AdministratorList;
|
|
|
|
|
+ apiKey?: Maybe<ApiKey>;
|
|
|
|
|
+ apiKeys: ApiKeyList;
|
|
|
/** Get a single Asset by id */
|
|
/** Get a single Asset by id */
|
|
|
asset?: Maybe<Asset>;
|
|
asset?: Maybe<Asset>;
|
|
|
/** Get a list of Assets */
|
|
/** Get a list of Assets */
|
|
@@ -5283,6 +5433,16 @@ export type QueryAdministratorsArgs = {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+export type QueryApiKeyArgs = {
|
|
|
|
|
+ id: Scalars['ID']['input'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+export type QueryApiKeysArgs = {
|
|
|
|
|
+ options?: InputMaybe<ApiKeyListOptions>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
export type QueryAssetArgs = {
|
|
export type QueryAssetArgs = {
|
|
|
id: Scalars['ID']['input'];
|
|
id: Scalars['ID']['input'];
|
|
|
};
|
|
};
|
|
@@ -5832,6 +5992,12 @@ export type RoleSortParameter = {
|
|
|
updatedAt?: InputMaybe<SortOrder>;
|
|
updatedAt?: InputMaybe<SortOrder>;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
+export type RotateApiKeyResult = {
|
|
|
|
|
+ __typename?: 'RotateApiKeyResult';
|
|
|
|
|
+ /** The generated API-Key. API-Keys cannot be viewed again after creation! */
|
|
|
|
|
+ apiKey: Scalars['String']['output'];
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
export type Sale = Node & StockMovement & {
|
|
export type Sale = Node & StockMovement & {
|
|
|
__typename?: 'Sale';
|
|
__typename?: 'Sale';
|
|
|
createdAt: Scalars['DateTime']['output'];
|
|
createdAt: Scalars['DateTime']['output'];
|
|
@@ -6612,6 +6778,26 @@ export type UpdateAdministratorInput = {
|
|
|
roleIds?: InputMaybe<Array<Scalars['ID']['input']>>;
|
|
roleIds?: InputMaybe<Array<Scalars['ID']['input']>>;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
+export type UpdateApiKeyInput = {
|
|
|
|
|
+ customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
|
|
+ /** ID of the ApiKey */
|
|
|
|
|
+ id: Scalars['ID']['input'];
|
|
|
|
|
+ /**
|
|
|
|
|
+ * Which roles to attach to this ApiKey.
|
|
|
|
|
+ * You may only grant roles which you, yourself have.
|
|
|
|
|
+ */
|
|
|
|
|
+ roleIds?: InputMaybe<Array<Scalars['ID']['input']>>;
|
|
|
|
|
+ translations?: InputMaybe<Array<UpdateApiKeyTranslationInput>>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
|
|
+export type UpdateApiKeyTranslationInput = {
|
|
|
|
|
+ customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
|
|
+ id?: InputMaybe<Scalars['ID']['input']>;
|
|
|
|
|
+ languageCode: LanguageCode;
|
|
|
|
|
+ /** A descriptive name so you can remind yourself where the API-Key gets used */
|
|
|
|
|
+ name?: InputMaybe<Scalars['String']['input']>;
|
|
|
|
|
+};
|
|
|
|
|
+
|
|
|
export type UpdateAssetInput = {
|
|
export type UpdateAssetInput = {
|
|
|
customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
customFields?: InputMaybe<Scalars['JSON']['input']>;
|
|
|
focalPoint?: InputMaybe<CoordinateInput>;
|
|
focalPoint?: InputMaybe<CoordinateInput>;
|