1.1.7 • Published 2 years ago

verifymycontent-moderation v1.1.7

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

VerifyMyContent Moderation Node SDK

Installation

$ npm install verifymycontent-moderation --save
// or
$ yarn add verifymycontent-moderation

Usage

import { ModerationClient } from 'verifymycontent-moderation'
;(async function () {
  const Client = new ModerationClient({
    apiKey: 'YOUR_API_KEY',
    apiSecret: 'YOUR_API_SECRET',
    // useSandbox: true,
  })

  const moderation = await Client.createModeration({
    content: {
      id: 'YOUR-CONTENT-ID',
      url: 'https://...',
      type: 'video',
      title: 'My video',
      description: 'My description',
    },
    customer: {
      id: 'YOUR-CUSTOMER-ID',
      email: 'customer@email.com',
      // phone: '+1-555-555-5555', // (optional)
    },
    webhook: 'https://...',
  })

  console.log(
    `Moderation created: ${moderation.id} - Current status: ${moderation.status}`
  )

  setTimeout(() => {
    console.log(`Getting moderation ${moderation.id} after 5 seconds`)
    Client.getModeration(moderation.id).then((moderation) => {
      console.log(
        `Moderation ${moderation.id} after 5 seconds - Current status: ${moderation.status}`
      )
    })
  }, 5000)
})()

Documentation

1.1.7

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago