Jon/improve cache key value deletion (#3464)
This commit is contained in:
@@ -379,7 +379,7 @@ function Workspace({
|
|||||||
const client = await getClient(credentialGetter, "sans-api-v1");
|
const client = await getClient(credentialGetter, "sans-api-v1");
|
||||||
const encodedCacheKeyValue = encodeURIComponent(cacheKeyValue);
|
const encodedCacheKeyValue = encodeURIComponent(cacheKeyValue);
|
||||||
return client.delete(
|
return client.delete(
|
||||||
`/scripts/${workflowPermanentId}/value/${encodedCacheKeyValue}`,
|
`/scripts/${workflowPermanentId}/value/?cache-key-value=${encodedCacheKeyValue}`,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
onSuccess: () => {
|
onSuccess: () => {
|
||||||
|
|||||||
@@ -485,12 +485,12 @@ async def get_workflow_cache_key_values(
|
|||||||
|
|
||||||
|
|
||||||
@base_router.delete(
|
@base_router.delete(
|
||||||
"/scripts/{workflow_permanent_id}/value/{cache_key_value}",
|
"/scripts/{workflow_permanent_id}/value",
|
||||||
include_in_schema=False,
|
include_in_schema=False,
|
||||||
)
|
)
|
||||||
async def delete_workflow_cache_key_value(
|
async def delete_workflow_cache_key_value(
|
||||||
workflow_permanent_id: str,
|
workflow_permanent_id: str,
|
||||||
cache_key_value: str,
|
cache_key_value: str = Query(alias="cache-key-value"),
|
||||||
current_org: Organization = Depends(org_auth_service.get_current_org),
|
current_org: Organization = Depends(org_auth_service.get_current_org),
|
||||||
) -> dict[str, str]:
|
) -> dict[str, str]:
|
||||||
"""Delete a specific cache key value for a workflow."""
|
"""Delete a specific cache key value for a workflow."""
|
||||||
|
|||||||
Reference in New Issue
Block a user