Modulify

Check a folder slug is free

check_folder_slug_available

Checks whether a folder slug is free in a workspace before update_folder_slug takes it.

It answers ok when the slug is free and not-ok when a folder in the workspace already holds it. It is no use before create_folder, which takes no slug and always derives its own.

A slug that is not 3 to 32 characters of letters, numbers and hyphens comes back as an error rather than as taken. Pass currentSlug when checking on behalf of an existing folder, and a slug equal to it is answered ok without a lookup. See Folders.

Inputs

Input Type Required Description
workspaceId string Yes The workspace to check within.
slug string Yes The slug to test.
currentSlug string No The slug the folder holds today, so it is not counted against itself.