🚀CRUDIFY

SocialMediaSimple


JSON Schema

{
  "username": {
    "type": "string"
  },
  "avatar": {
    "type": "string"
  },
  "createdAt": {
    "type": "string"
  },
  "media": {
    "type": "array",
    "entries": {
      "type": "string"
    }
  },
  "text": {
    "type": "string"
  }
}

Zod Validator

⚠️ zod validator is a work in progress

const validator = z.object({
  "username": z.string(),
  "avatar": z.string(),
  "createdAt": z.string(),
  "media": z.array(z.string()),
  "text": z.string()
})

API Documentation

GET https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple

- Gets all data for entity

Request Body

null

Response Body

type Response = (typeof validator._input & { id: string })[]

POST https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple

- Creates a data entry for entity

Request Body

type Request = typeof validator._input

Response Body

type Response = (typeof validator._input & { id: string })

GET https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple/:entityID

- Gets a data entry for entity by id

Request Body

null

Response Body

type Response = (typeof validator._input & { id: string })

POST https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple/where

- Finds one entity matching the query

Request Body

type Request = { [dotpath: string]: any }

Response Body

type Response = (typeof validator._input & { id: string })

PUT https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple/:entityID

- Updates a data entry for entity by id

Request Body

type Request = typeof validator._input

Response Body

type Response = (typeof validator._input & { id: string })

DELETE https://crudify.app/api/user/iTduz8WS9Cug4-cH/SocialMediaSimple/:entityID

- Deletes a data entry for entity by id

Request Body

null

Response Body

type Response = (typeof validator._input & { id: string })