Show examples in:
Retrieve all fields using the plugin

Returns

Returns an array of field resource objects.

Examples

Example Basic example
import { buildClient } from '@datocms/cma-client-node';
async function run() {
const client = buildClient({ apiToken: '<YOUR_API_TOKEN>' });
const pluginId = 'RMAMRffBRlmBuDlQsIWZ0g';
const plugins = await client.plugins.fields(pluginId);
plugins.forEach((plugin) => {
console.log(plugin);
});
}
run();