Shortcode.ts 453 B

123456789101112131415
  1. import { runMutation } from "../GQLClient"
  2. import {
  3. CreateShortcodeDocument,
  4. CreateShortcodeMutation,
  5. CreateShortcodeMutationVariables,
  6. } from "../graphql"
  7. import { HoppRESTRequest } from "~/helpers/types/HoppRESTRequest"
  8. export const createShortcode = (request: HoppRESTRequest) =>
  9. runMutation<CreateShortcodeMutation, CreateShortcodeMutationVariables, "">(
  10. CreateShortcodeDocument,
  11. {
  12. request: JSON.stringify(request),
  13. }
  14. )