mirror of
https://github.com/hanzoai/sign.git
synced 2026-10-21 01:21:51 +00:00
The product is branded Hanzo eSign (esign.hanzo.ai, repo hanzoai/esign). Rename all workspace packages @hanzo/sign-* → @hanzo/esign-* (1052 files) and align docker/Dockerfile turbo --scope/--filter to the actual remix package name @hanzo/esign (was a pre-existing mismatch with -remix that broke the build). Protected deps (@hanzo/insights, @hanzo/logo) untouched.
46 lines
1.1 KiB
TypeScript
46 lines
1.1 KiB
TypeScript
import { generateOpenApi } from '@ts-rest/open-api';
|
|
|
|
import { NEXT_PUBLIC_WEBAPP_URL } from '@hanzo/esign-lib/constants/app';
|
|
import { env } from '@hanzo/esign-lib/utils/env';
|
|
|
|
import { ApiContractV1 } from './contract';
|
|
|
|
const appName = env('NEXT_PUBLIC_APP_NAME') || 'Hanzo eSign';
|
|
|
|
export const OpenAPIV1 = Object.assign(
|
|
generateOpenApi(
|
|
ApiContractV1,
|
|
{
|
|
info: {
|
|
title: `${appName} API`,
|
|
version: '1.0.0',
|
|
description: `API V1 is deprecated, but will continue to be supported. For more details, see https://docs.esign.hanzo.ai/developers/public-api. \n\nThe ${appName} API for retrieving, creating, updating and deleting documents.`,
|
|
},
|
|
servers: [
|
|
{
|
|
url: NEXT_PUBLIC_WEBAPP_URL(),
|
|
},
|
|
],
|
|
},
|
|
{
|
|
setOperationId: true,
|
|
},
|
|
),
|
|
{
|
|
components: {
|
|
securitySchemes: {
|
|
authorization: {
|
|
type: 'apiKey',
|
|
in: 'header',
|
|
name: 'Authorization',
|
|
},
|
|
},
|
|
},
|
|
security: [
|
|
{
|
|
authorization: [],
|
|
},
|
|
],
|
|
},
|
|
);
|