Modulify

Read the AI media preferences

get_ai_preferences

Reads the AI media preferences of a site, the settings that decide what its generated pictures and clips cost.

These are the settings on the site's Preferences tab: whether paid images and video are on at all, the image model and largest image size, and the video model, longest clip, clip resolution and whether visitors can unmute clips. ImageGenerationDisabled is true while paid media is off, and a setting left on automatic or its default comes back as null.

The response also lists every model, size, resolution and length you can pick, each priced in credits at the workspace's current plan, and a Summary with one plain line per setting that names the model an automatic choice uses. Each image model says whether it follows the size setting, how large it goes, what an edit costs and which model makes its edits, which is a different one when the model cannot edit. Each video model lists the clip lengths and resolutions it takes and whether it makes sound, and recommended marks the model automatic follows. A model that is not available right now is left out, so the choices can change over time.

The tool tells the client to read this before update_ai_preferences, so it passes valid values and can tell you what a change will cost. See Preferences.

Inputs

Input Type Required Description
projectId string Yes The site id.