--- title: "Image moderation" url: https://docs.catalyst.zoho.com/en/sdk/nodejs/v2/zia-services/image-moderation/ description: "This page describes the method to use the Image Moderation feature to detect vulnerability in images within your NodeJS application with sample code snippets" last_updated: 2026-09-08T11:07:33Z service: Zia Services type: general related_links: - name: "Image moderation - API" url: /en/api/code-reference/zia-services/image-moderation/#ImageModeration --- # Image Moderation > **Note:** This SDK is currently in deprecation. Migrate to [JavaScript SDK](https://docs.catalyst.zoho.com/en/sdk/javascript/v1/zia-services/image-moderation/) now. [Image Moderation](https://docs.catalyst.zoho.com/en/zia-services/help/image-moderation/introduction) detects and recognizes inappropriate and unsafe content in images. The criteria include suggestive or explicit racy content, nudity, violence, gore, bloodshed, and the presence of weapons and drugs. You can provide a ._jpg_/._jpeg_ or ._png_ file as the input. Refer to the [API documentation](https://docs.catalyst.zoho.com/en/api/code-reference/zia-services/image-moderation/#ImageModeration) for the request and response formats. You can set the moderation mode as `BASIC`, `MODERATE`, or `ADVANCED` optionally. The image is processed in the `ADVANCED` mode by default. The response returns the probability of each criteria with their confidence scores, and the prediction of the image being `safe_to_use` or `unsafe_to_use`. The `zia` reference used below is defined in the [component instance page.](https://docs.catalyst.zoho.com/en/sdk/nodejs/v2/zia-services/get-component-instance)The promise returned here is resolved to a JSON object. ```javascript let fs = require('fs'); zia.moderateImage(fs.createReadStream('./weapon.png'), {mode: 'moderate'}) //Pass the input file and the mode .then((result) => { console.log(result); }).catch((err) => console.log(err.toString())); //Push errors to Catalyst Logs ``` A sample response that you will receive is shown below. The response is the same for both versions of Node.js. #### Node js ```json {"probability":{"racy":"0.09","nudity":"0.06"},"confidence":"0.85","prediction":"safe_to#_use"} ```