const $lib: TypeSpecLibrary<{
api-version-not-string: {
default: "Api version must be a string or a string enum";
default: CallableMessage<["name"]>;
conflict-access-override: {
default: "@access override conflicts with the access calculated from operation or other @access override.";
conflict-usage-override: {
default: "@usage override conflicts with the usage calculated from operation or other @usage override.";
conflicting-multipart-model-usage: {
default: CallableMessage<["modelName", "modelName", "modelName"]>;
discriminator-not-constant: {
default: CallableMessage<["discriminator"]>;
discriminator-not-string: {
default: CallableMessage<["discriminator", "discriminatorValue"]>;
default: CallableMessage<["name", "scope"]>;
nonDecorator: CallableMessage<["name", "scope"]>;
default: CallableMessage<["decoratorName"]>;
duplicate-example-file: {
default: CallableMessage<["filename", "title", "operationId"]>;
default: "Cannot pass an empty value to the @clientName decorator";
empty-client-namespace: {
default: "Cannot pass an empty value to the @clientNamespace decorator";
encoding-multipart-bytes: {
default: "Encoding should not be applied to bytes content in a multipart request. This is semi-incompatible with how multipart works in HTTP.";
default: CallableMessage<["filename", "error"]>;
noDirectory: CallableMessage<["directory"]>;
noOperationId: CallableMessage<["filename"]>;
example-value-no-mapping: {
default: CallableMessage<["relativePath", "value"]>;
default: "Cannot flatten property of polymorphic type.";
default: "Access value must be \"public\" or \"internal\".";
invalid-alternate-source-type: {
default: CallableMessage<["typeName"]>;
invalid-encode-for-collection-format: {
default: "Only encode of `ArrayEncoding.pipeDelimited` and `ArrayEncoding.spaceDelimited` is supported for collection format.";
invalid-initialized-by: {
default: CallableMessage<["message"]>;
default: "Usage value must be 2 (\"input\") or 4 (\"output\").";
multiple-response-types: {
default: CallableMessage<["operation", "response"]>;
default: CallableMessage<["service"]>;
no-corresponding-method-param: {
default: CallableMessage<["paramName", "methodName", "paramName", "paramName"]>;
no-discriminated-unions: {
default: "Discriminated unions are not supported. Please redefine the type using model with hierarchy and `@discriminator` decorator.";
default: "Can not find name for your emitter, please check your emitter name.";
override-method-parameters-mismatch: {
default: CallableMessage<["methodName", "originalParameters", "overrideParameters"]>;
default: CallableMessage<["templateArgumentName", "templateArgumentType"]>;
unexpected-http-param-type: {
default: CallableMessage<["paramName", "expectedType", "actualType"]>;
unexpected-pageable-operation-return-type: {
default: "Operation is pageable but does not return a correct type.";
default: "Cannot have a union containing self.";
default: "Cannot have a union containing only null types.";
unsupported-generic-decorator-arg-type: {
default: CallableMessage<["decoratorName"]>;
default: CallableMessage<["kind"]>;
default: "Currently we only support HTTP and HTTPS protocols";
wrong-client-decorator: {
default: "@client or @operationGroup should decorate namespace or interface in client.tsp";
}, SdkEmitterOptions, never>;