Skip to content

armgit / umami

Public Imported from GitHub
0

Umami is a privacy-first web and product analytics platform. Traffic, campaigns, behavior, conversions, and revenue in one place. No cookies, no surveillance, self-hosted or in the cloud.

2.6 KB
Raw Blame
// Generated by `pnpm openapi:contracts`. Do not edit directly.

import type { ZodOpenApiOperationObject } from 'zod-openapi';
import { defineOperation } from '@/openapi/operation';

const operation1 = defineOperation({
  method: 'get',
  path: '/api/websites/{websiteId}/recorder',
  audience: 'collect',
  auth: 'none',
  operation: {
    operationId: 'getWebsiteRecorderConfig',
    summary: 'Get websites website id recorder',
    tags: ['Websites'],
    parameters: [
      {
        name: 'websiteId',
        in: 'path',
        required: true,
        schema: {
          type: 'string',
        },
      },
    ],
    responses: {
      '200': {
        description: 'The operation completed successfully.',
        content: {
          'application/json': {
            schema: {
              anyOf: [
                {
                  type: 'object',
                  properties: {
                    enabled: {
                      type: 'boolean',
                    },
                  },
                  required: ['enabled'],
                },
                {
                  type: 'object',
                  properties: {
                    enabled: {
                      type: 'boolean',
                    },
                    replayEnabled: {
                      type: 'boolean',
                    },
                    heatmapEnabled: {
                      type: 'boolean',
                    },
                    sampleRate: {
                      type: 'number',
                    },
                    heatmapSampleRate: {
                      type: 'number',
                    },
                    maskLevel: {
                      anyOf: [
                        {
                          const: 'strict',
                        },
                        {
                          const: 'moderate',
                        },
                      ],
                    },
                    maxDuration: {
                      type: 'number',
                    },
                    blockSelector: {
                      type: 'string',
                    },
                  },
                  required: [
                    'enabled',
                    'replayEnabled',
                    'heatmapEnabled',
                    'sampleRate',
                    'heatmapSampleRate',
                    'maskLevel',
                    'maxDuration',
                    'blockSelector',
                  ],
                },
              ],
            },
          },
        },
      },
    },
  } as ZodOpenApiOperationObject,
});

export const operations = [operation1] as const;