diff --git a/kittycad.py.patch.json b/kittycad.py.patch.json index 884d33a3c..e7826d749 100644 --- a/kittycad.py.patch.json +++ b/kittycad.py.patch.json @@ -1,114 +1,90 @@ [ { "op": "add", - "path": "/info/x-python", - "value": { - "client": "# Create a client with your token.\nfrom kittycad import Client\n\nclient = Client(token=\"$TOKEN\")\n\n# - OR -\n\n# Create a new client with your token parsed from the environment variable:\n# `KITTYCAD_API_TOKEN`.\nfrom kittycad import ClientFromEnv\n\nclient = ClientFromEnv()\n\n# NOTE: The python library additionally implements asyncio, however all the code samples we\n# show below use the sync functions for ease of use and understanding.\n# Check out the library docs at:\n# https://python.api.docs.kittycad.io/_autosummary/kittycad.api.html#module-kittycad.api\n# for more details.", - "install": "pip install kittycad" - } - }, - { - "op": "add", - "path": "/paths/~1user~1payment~1methods~1{id}/delete/x-python", - "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import delete_payment_method_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_delete_payment_method_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = delete_payment_method_for_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.delete_payment_method_for_user.html" - } - }, - { - "op": "add", - "path": "/paths/~1unit~1conversion~1length~1{input_unit}~1{output_unit}/get/x-python", - "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_length_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitLengthConversion\nfrom kittycad.models.unit_length import UnitLength\nfrom kittycad.types import Response\n\n\ndef example_get_length_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitLengthConversion, Error]\n ] = get_length_unit_conversion.sync(\n client=client,\n input_unit=UnitLength.CM,\n output_unit=UnitLength.CM,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitLengthConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_length_unit_conversion.html" - } - }, - { - "op": "add", - "path": "/paths/~1_meta~1info/get/x-python", + "path": "/paths/~1openai~1openapi.json/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import get_metadata\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Metadata\nfrom kittycad.types import Response\n\n\ndef example_get_metadata():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Metadata, Error]] = get_metadata.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Metadata = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_metadata.html" + "example": "from kittycad.api.meta import get_openai_schema\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_openai_schema():\n # Create our client.\n client = ClientFromEnv()\n\n get_openai_schema.sync(\n client=client,\n )\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_openai_schema.html" } }, { "op": "add", - "path": "/paths/~1file~1volume/post/x-python", + "path": "/paths/~1users-extended/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_volume\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileVolume\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_volume import UnitVolume\nfrom kittycad.types import Response\n\n\ndef example_create_file_volume():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileVolume, Error]] = create_file_volume.sync(\n client=client,\n output_unit=UnitVolume.CM3,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileVolume = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_volume.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import list_users_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUserResultsPage\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_users_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ExtendedUserResultsPage, Error]\n ] = list_users_extended.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUserResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.list_users_extended.html" } }, { "op": "add", - "path": "/paths/~1ai~1text-to-3d~1{output_format}/post/x-python", + "path": "/paths/~1apps~1github~1webhook/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.ai import create_text_to_3d\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Mesh\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.types import Response\n\n\ndef example_create_text_to_3d():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Mesh, Error]] = create_text_to_3d.sync(\n client=client,\n output_format=FileExportFormat.FBX,\n prompt=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Mesh = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.ai.create_text_to_3d.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_webhook\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_webhook():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = apps_github_webhook.sync(\n client=client,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_webhook.html" } }, { "op": "add", - "path": "/paths/~1api-calls/get/x-python", + "path": "/paths/~1api-calls~1{id}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_api_calls\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_calls():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = list_api_calls.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_api_calls.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPrice, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_call():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiCallWithPrice, Error]] = get_api_call.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPrice = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call.html" } }, { "op": "add", - "path": "/paths/~1ai~1image-to-3d~1{input_format}~1{output_format}/post/x-python", + "path": "/paths/~1unit~1conversion~1torque~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.ai import create_image_to_3d\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Mesh\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.models.image_type import ImageType\nfrom kittycad.types import Response\n\n\ndef example_create_image_to_3d():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Mesh, Error]] = create_image_to_3d.sync(\n client=client,\n input_format=ImageType.PNG,\n output_format=FileExportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Mesh = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.ai.create_image_to_3d.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_torque_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitTorqueConversion\nfrom kittycad.models.unit_torque import UnitTorque\nfrom kittycad.types import Response\n\n\ndef example_get_torque_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitTorqueConversion, Error]\n ] = get_torque_unit_conversion.sync(\n client=client,\n input_unit=UnitTorque.NEWTON_METRES,\n output_unit=UnitTorque.NEWTON_METRES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitTorqueConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_torque_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1api-calls~1{id}/get/x-python", + "path": "/paths/~1api-call-metrics/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPrice, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_call():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiCallWithPrice, Error]] = get_api_call.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPrice = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call_metrics\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallQueryGroup, Error\nfrom kittycad.models.api_call_query_group_by import ApiCallQueryGroupBy\nfrom kittycad.types import Response\n\n\ndef example_get_api_call_metrics():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[List[ApiCallQueryGroup], Error]\n ] = get_api_call_metrics.sync(\n client=client,\n group_by=ApiCallQueryGroupBy.EMAIL,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[ApiCallQueryGroup] = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call_metrics.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1angle~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1user~1api-tokens~1{token}/delete/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_angle_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitAngleConversion\nfrom kittycad.models.unit_angle import UnitAngle\nfrom kittycad.types import Response\n\n\ndef example_get_angle_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitAngleConversion, Error]\n ] = get_angle_unit_conversion.sync(\n client=client,\n input_unit=UnitAngle.DEGREES,\n output_unit=UnitAngle.DEGREES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitAngleConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_angle_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import delete_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_delete_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = delete_api_token_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.delete_api_token_for_user.html" } }, { "op": "add", - "path": "/paths/~1users/get/x-python", + "path": "/paths/~1user~1api-tokens~1{token}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import list_users\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UserResultsPage\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_users():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[UserResultsPage, Error]] = list_users.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UserResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.list_users.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import get_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiToken, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiToken, Error]] = get_api_token_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiToken = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.get_api_token_for_user.html" } }, { "op": "add", - "path": "/paths/~1ws~1modeling~1commands/get/x-python", + "path": "/paths/~1unit~1conversion~1length~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from kittycad.api.modeling import modeling_commands_ws\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_modeling_commands_ws():\n # Create our client.\n client = ClientFromEnv()\n\n # Connect to the websocket.\n websocket = modeling_commands_ws.sync(\n client=client,\n fps=10,\n unlocked_framerate=False,\n video_res_height=10,\n video_res_width=10,\n webrtc=False,\n )\n\n # Send a message.\n websocket.send(\"{}\")\n\n # Get the messages.\n for message in websocket:\n print(message)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.modeling.modeling_commands_ws.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_length_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitLengthConversion\nfrom kittycad.models.unit_length import UnitLength\nfrom kittycad.types import Response\n\n\ndef example_get_length_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitLengthConversion, Error]\n ] = get_length_unit_conversion.sync(\n client=client,\n input_unit=UnitLength.CM,\n output_unit=UnitLength.CM,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitLengthConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_length_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1ping/get/x-python", + "path": "/paths/~1apps~1github~1consent/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import ping\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Pong\nfrom kittycad.types import Response\n\n\ndef example_ping():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Pong, Error]] = ping.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Pong = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.ping.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_consent\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AppClientInfo, Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_consent():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[AppClientInfo, Error]] = apps_github_consent.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AppClientInfo = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_consent.html" } }, { "op": "add", - "path": "/paths/~1user~1payment~1methods/get/x-python", + "path": "/paths/~1unit~1conversion~1current~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import list_payment_methods_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, PaymentMethod\nfrom kittycad.types import Response\n\n\ndef example_list_payment_methods_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[List[PaymentMethod], Error]\n ] = list_payment_methods_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[PaymentMethod] = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.list_payment_methods_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_current_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitCurrentConversion\nfrom kittycad.models.unit_current import UnitCurrent\nfrom kittycad.types import Response\n\n\ndef example_get_current_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitCurrentConversion, Error]\n ] = get_current_unit_conversion.sync(\n client=client,\n input_unit=UnitCurrent.AMPERES,\n output_unit=UnitCurrent.AMPERES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitCurrentConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_current_unit_conversion.html" } }, { @@ -121,18 +97,18 @@ }, { "op": "add", - "path": "/paths/~1file~1conversion~1{src_format}~1{output_format}/post/x-python", + "path": "/paths/~1user~1payment~1balance/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileConversion\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.types import Response\n\n\ndef example_create_file_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileConversion, Error]] = create_file_conversion.sync(\n client=client,\n output_format=FileExportFormat.FBX,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import get_payment_balance_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import CustomerBalance, Error\nfrom kittycad.types import Response\n\n\ndef example_get_payment_balance_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[CustomerBalance, Error]\n ] = get_payment_balance_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: CustomerBalance = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.get_payment_balance_for_user.html" } }, { "op": "add", - "path": "/paths/~1.well-known~1ai-plugin.json/get/x-python", + "path": "/paths/~1user~1payment/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import get_ai_plugin_manifest\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AiPluginManifest, Error\nfrom kittycad.types import Response\n\n\ndef example_get_ai_plugin_manifest():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[AiPluginManifest, Error]\n ] = get_ai_plugin_manifest.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AiPluginManifest = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_ai_plugin_manifest.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import get_payment_information_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Customer, Error\nfrom kittycad.types import Response\n\n\ndef example_get_payment_information_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[Customer, Error]\n ] = get_payment_information_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Customer = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.get_payment_information_for_user.html" } }, { @@ -143,14 +119,6 @@ "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.delete_payment_information_for_user.html" } }, - { - "op": "add", - "path": "/paths/~1user~1payment/get/x-python", - "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import get_payment_information_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Customer, Error\nfrom kittycad.types import Response\n\n\ndef example_get_payment_information_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[Customer, Error]\n ] = get_payment_information_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Customer = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.get_payment_information_for_user.html" - } - }, { "op": "add", "path": "/paths/~1user~1payment/put/x-python", @@ -169,26 +137,18 @@ }, { "op": "add", - "path": "/paths/~1users-extended/get/x-python", - "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import list_users_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUserResultsPage\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_users_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ExtendedUserResultsPage, Error]\n ] = list_users_extended.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUserResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.list_users_extended.html" - } - }, - { - "op": "add", - "path": "/paths/~1unit~1conversion~1current~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1ai~1image-to-3d~1{input_format}~1{output_format}/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_current_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitCurrentConversion\nfrom kittycad.models.unit_current import UnitCurrent\nfrom kittycad.types import Response\n\n\ndef example_get_current_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitCurrentConversion, Error]\n ] = get_current_unit_conversion.sync(\n client=client,\n input_unit=UnitCurrent.AMPERES,\n output_unit=UnitCurrent.AMPERES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitCurrentConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_current_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.ai import create_image_to_3d\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Mesh\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.models.image_type import ImageType\nfrom kittycad.types import Response\n\n\ndef example_create_image_to_3d():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Mesh, Error]] = create_image_to_3d.sync(\n client=client,\n input_format=ImageType.PNG,\n output_format=FileExportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Mesh = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.ai.create_image_to_3d.html" } }, { "op": "add", - "path": "/paths/~1file~1surface-area/post/x-python", + "path": "/paths/~1auth~1email/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_surface_area\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileSurfaceArea\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_area import UnitArea\nfrom kittycad.types import Response\n\n\ndef example_create_file_surface_area():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[FileSurfaceArea, Error]\n ] = create_file_surface_area.sync(\n client=client,\n output_unit=UnitArea.CM2,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileSurfaceArea = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_surface_area.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.hidden import auth_email\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, VerificationToken\nfrom kittycad.models.email_authentication_form import EmailAuthenticationForm\nfrom kittycad.types import Response\n\n\ndef example_auth_email():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[VerificationToken, Error]] = auth_email.sync(\n client=client,\n body=EmailAuthenticationForm(\n email=\"\",\n ),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: VerificationToken = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.hidden.auth_email.html" } }, { @@ -201,10 +161,10 @@ }, { "op": "add", - "path": "/paths/~1unit~1conversion~1temperature~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1users-extended~1{id}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_temperature_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitTemperatureConversion\nfrom kittycad.models.unit_temperature import UnitTemperature\nfrom kittycad.types import Response\n\n\ndef example_get_temperature_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitTemperatureConversion, Error]\n ] = get_temperature_unit_conversion.sync(\n client=client,\n input_unit=UnitTemperature.CELSIUS,\n output_unit=UnitTemperature.CELSIUS,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitTemperatureConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_temperature_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUser\nfrom kittycad.types import Response\n\n\ndef example_get_user_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ExtendedUser, Error]] = get_user_extended.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUser = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_extended.html" } }, { @@ -233,202 +193,234 @@ }, { "op": "add", - "path": "/paths/~1users~1{id}/get/x-python", + "path": "/paths/~1api-calls/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, User\nfrom kittycad.types import Response\n\n\ndef example_get_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[User, Error]] = get_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: User = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_api_calls\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_calls():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = list_api_calls.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_api_calls.html" } }, { "op": "add", - "path": "/paths/~1user~1onboarding/get/x-python", + "path": "/paths/~1user~1front-hash/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_onboarding_self\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Onboarding\nfrom kittycad.types import Response\n\n\ndef example_get_user_onboarding_self():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Onboarding, Error]] = get_user_onboarding_self.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Onboarding = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_onboarding_self.html" + "example": "from kittycad.api.users import get_user_front_hash_self\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_user_front_hash_self():\n # Create our client.\n client = ClientFromEnv()\n\n get_user_front_hash_self.sync(\n client=client,\n )\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_front_hash_self.html" } }, { "op": "add", - "path": "/paths/~1user~1payment~1invoices/get/x-python", + "path": "/paths/~1file~1mass/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import list_invoices_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Invoice\nfrom kittycad.types import Response\n\n\ndef example_list_invoices_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[List[Invoice], Error]] = list_invoices_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[Invoice] = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.list_invoices_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_mass\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileMass\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_density import UnitDensity\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_create_file_mass():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileMass, Error]] = create_file_mass.sync(\n client=client,\n material_density=3.14,\n material_density_unit=UnitDensity.LB_FT3,\n output_unit=UnitMass.G,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileMass = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_mass.html" } }, { "op": "add", - "path": "/paths/~1openai~1openapi.json/get/x-python", + "path": "/paths/~1unit~1conversion~1angle~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from kittycad.api.meta import get_openai_schema\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_openai_schema():\n # Create our client.\n client = ClientFromEnv()\n\n get_openai_schema.sync(\n client=client,\n )\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_openai_schema.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_angle_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitAngleConversion\nfrom kittycad.models.unit_angle import UnitAngle\nfrom kittycad.types import Response\n\n\ndef example_get_angle_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitAngleConversion, Error]\n ] = get_angle_unit_conversion.sync(\n client=client,\n input_unit=UnitAngle.DEGREES,\n output_unit=UnitAngle.DEGREES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitAngleConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_angle_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1user~1session~1{token}/get/x-python", + "path": "/paths/~1file~1volume/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_session_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Session\nfrom kittycad.types import Response\n\n\ndef example_get_session_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Session, Error]] = get_session_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Session = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_session_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_volume\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileVolume\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_volume import UnitVolume\nfrom kittycad.types import Response\n\n\ndef example_create_file_volume():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileVolume, Error]] = create_file_volume.sync(\n client=client,\n output_unit=UnitVolume.CM3,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileVolume = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_volume.html" } }, { "op": "add", - "path": "/paths/~1file~1execute~1{lang}/post/x-python", + "path": "/paths/~1ws~1executor~1term/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.executor import create_file_execution\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import CodeOutput, Error\nfrom kittycad.models.code_language import CodeLanguage\nfrom kittycad.types import Response\n\n\ndef example_create_file_execution():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[CodeOutput, Error]] = create_file_execution.sync(\n client=client,\n lang=CodeLanguage.GO,\n output=None, # Optional[str]\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: CodeOutput = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.executor.create_file_execution.html" + "example": "from kittycad.api.executor import create_executor_term\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_create_executor_term():\n # Create our client.\n client = ClientFromEnv()\n\n # Connect to the websocket.\n websocket = create_executor_term.sync(\n client=client,\n )\n\n # Send a message.\n websocket.send(\"{}\")\n\n # Get the messages.\n for message in websocket:\n print(message)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.executor.create_executor_term.html" } }, { "op": "add", - "path": "/paths/~1user~1api-calls/get/x-python", + "path": "/paths/~1_meta~1info/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import user_list_api_calls\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_user_list_api_calls():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = user_list_api_calls.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.user_list_api_calls.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import get_metadata\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Metadata\nfrom kittycad.types import Response\n\n\ndef example_get_metadata():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Metadata, Error]] = get_metadata.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Metadata = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_metadata.html" } }, { "op": "add", - "path": "/paths/~1user~1api-calls~1{id}/get/x-python", + "path": "/paths/~1unit~1conversion~1energy~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPrice, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_call_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiCallWithPrice, Error]] = get_api_call_for_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPrice = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_energy_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitEnergyConversion\nfrom kittycad.models.unit_energy import UnitEnergy\nfrom kittycad.types import Response\n\n\ndef example_get_energy_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitEnergyConversion, Error]\n ] = get_energy_unit_conversion.sync(\n client=client,\n input_unit=UnitEnergy.BTU,\n output_unit=UnitEnergy.BTU,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitEnergyConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_energy_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1apps~1github~1webhook/post/x-python", + "path": "/paths/~1user~1onboarding/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_webhook\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_webhook():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = apps_github_webhook.sync(\n client=client,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_webhook.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_onboarding_self\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Onboarding\nfrom kittycad.types import Response\n\n\ndef example_get_user_onboarding_self():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Onboarding, Error]] = get_user_onboarding_self.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Onboarding = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_onboarding_self.html" } }, { "op": "add", - "path": "/paths/~1apps~1github~1consent/get/x-python", + "path": "/paths/~1unit~1conversion~1area~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_consent\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AppClientInfo, Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_consent():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[AppClientInfo, Error]] = apps_github_consent.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AppClientInfo = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_consent.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_area_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitAreaConversion\nfrom kittycad.models.unit_area import UnitArea\nfrom kittycad.types import Response\n\n\ndef example_get_area_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitAreaConversion, Error]\n ] = get_area_unit_conversion.sync(\n client=client,\n input_unit=UnitArea.CM2,\n output_unit=UnitArea.CM2,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitAreaConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_area_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1torque~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1user~1payment~1intent/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_torque_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitTorqueConversion\nfrom kittycad.models.unit_torque import UnitTorque\nfrom kittycad.types import Response\n\n\ndef example_get_torque_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitTorqueConversion, Error]\n ] = get_torque_unit_conversion.sync(\n client=client,\n input_unit=UnitTorque.NEWTON_METRES,\n output_unit=UnitTorque.NEWTON_METRES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitTorqueConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_torque_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import create_payment_intent_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, PaymentIntent\nfrom kittycad.types import Response\n\n\ndef example_create_payment_intent_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[PaymentIntent, Error]\n ] = create_payment_intent_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: PaymentIntent = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.create_payment_intent_for_user.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1area~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1file~1execute~1{lang}/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_area_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitAreaConversion\nfrom kittycad.models.unit_area import UnitArea\nfrom kittycad.types import Response\n\n\ndef example_get_area_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitAreaConversion, Error]\n ] = get_area_unit_conversion.sync(\n client=client,\n input_unit=UnitArea.CM2,\n output_unit=UnitArea.CM2,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitAreaConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_area_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.executor import create_file_execution\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import CodeOutput, Error\nfrom kittycad.models.code_language import CodeLanguage\nfrom kittycad.types import Response\n\n\ndef example_create_file_execution():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[CodeOutput, Error]] = create_file_execution.sync(\n client=client,\n lang=CodeLanguage.GO,\n output=None, # Optional[str]\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: CodeOutput = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.executor.create_file_execution.html" } }, { "op": "add", - "path": "/paths/~1file~1mass/post/x-python", + "path": "/paths/~1/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_mass\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileMass\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_density import UnitDensity\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_create_file_mass():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileMass, Error]] = create_file_mass.sync(\n client=client,\n material_density=3.14,\n material_density_unit=UnitDensity.LB_FT3,\n output_unit=UnitMass.G,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileMass = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_mass.html" + "example": "from kittycad.api.meta import get_schema\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_schema():\n # Create our client.\n client = ClientFromEnv()\n\n get_schema.sync(\n client=client,\n )\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_schema.html" } }, { "op": "add", - "path": "/paths/~1apps~1github~1callback/get/x-python", + "path": "/paths/~1unit~1conversion~1force~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_callback\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_callback():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = apps_github_callback.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_callback.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_force_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitForceConversion\nfrom kittycad.models.unit_force import UnitForce\nfrom kittycad.types import Response\n\n\ndef example_get_force_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitForceConversion, Error]\n ] = get_force_unit_conversion.sync(\n client=client,\n input_unit=UnitForce.DYNES,\n output_unit=UnitForce.DYNES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitForceConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_force_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1users~1{id}~1api-calls/get/x-python", + "path": "/paths/~1user~1api-tokens/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_api_calls_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_calls_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = list_api_calls_for_user.sync(\n client=client,\n id=\"\",\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_api_calls_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import create_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiToken, Error\nfrom kittycad.types import Response\n\n\ndef example_create_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiToken, Error]] = create_api_token_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiToken = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.create_api_token_for_user.html" } }, { "op": "add", - "path": "/paths/~1auth~1email/post/x-python", + "path": "/paths/~1user~1api-tokens/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.hidden import auth_email\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, VerificationToken\nfrom kittycad.models.email_authentication_form import EmailAuthenticationForm\nfrom kittycad.types import Response\n\n\ndef example_auth_email():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[VerificationToken, Error]] = auth_email.sync(\n client=client,\n body=EmailAuthenticationForm(\n email=\"\",\n ),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: VerificationToken = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.hidden.auth_email.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import list_api_tokens_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiTokenResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_tokens_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiTokenResultsPage, Error]\n ] = list_api_tokens_for_user.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiTokenResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.list_api_tokens_for_user.html" } }, { "op": "add", - "path": "/paths/~1async~1operations/get/x-python", + "path": "/paths/~1unit~1conversion~1power~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_async_operations\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AsyncApiCallResultsPage, Error\nfrom kittycad.models.api_call_status import ApiCallStatus\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_async_operations():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[AsyncApiCallResultsPage, Error]\n ] = list_async_operations.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n status=ApiCallStatus.QUEUED,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AsyncApiCallResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_async_operations.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_power_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitPowerConversion\nfrom kittycad.models.unit_power import UnitPower\nfrom kittycad.types import Response\n\n\ndef example_get_power_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitPowerConversion, Error]\n ] = get_power_unit_conversion.sync(\n client=client,\n input_unit=UnitPower.BTU_PER_MINUTE,\n output_unit=UnitPower.BTU_PER_MINUTE,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitPowerConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_power_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1file~1density/post/x-python", + "path": "/paths/~1user~1payment~1methods/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_density\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileDensity\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_density import UnitDensity\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_create_file_density():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileDensity, Error]] = create_file_density.sync(\n client=client,\n material_mass=3.14,\n material_mass_unit=UnitMass.G,\n output_unit=UnitDensity.LB_FT3,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileDensity = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_density.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import list_payment_methods_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, PaymentMethod\nfrom kittycad.types import Response\n\n\ndef example_list_payment_methods_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[List[PaymentMethod], Error]\n ] = list_payment_methods_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[PaymentMethod] = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.list_payment_methods_for_user.html" } }, { "op": "add", - "path": "/paths/~1user~1api-tokens/post/x-python", + "path": "/paths/~1unit~1conversion~1frequency~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import create_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiToken, Error\nfrom kittycad.types import Response\n\n\ndef example_create_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiToken, Error]] = create_api_token_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiToken = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.create_api_token_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_frequency_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitFrequencyConversion\nfrom kittycad.models.unit_frequency import UnitFrequency\nfrom kittycad.types import Response\n\n\ndef example_get_frequency_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitFrequencyConversion, Error]\n ] = get_frequency_unit_conversion.sync(\n client=client,\n input_unit=UnitFrequency.GIGAHERTZ,\n output_unit=UnitFrequency.GIGAHERTZ,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitFrequencyConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_frequency_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1user~1api-tokens/get/x-python", + "path": "/paths/~1logout/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import list_api_tokens_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiTokenResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_tokens_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiTokenResultsPage, Error]\n ] = list_api_tokens_for_user.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiTokenResultsPage = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.list_api_tokens_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.hidden import logout\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_logout():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = logout.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.hidden.logout.html" } }, { "op": "add", - "path": "/paths/~1/get/x-python", + "path": "/paths/~1users/get/x-python", "value": { - "example": "from kittycad.api.meta import get_schema\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_schema():\n # Create our client.\n client = ClientFromEnv()\n\n get_schema.sync(\n client=client,\n )\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_schema.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import list_users\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UserResultsPage\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_users():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[UserResultsPage, Error]] = list_users.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UserResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.list_users.html" } }, { "op": "add", - "path": "/paths/~1user~1payment~1intent/post/x-python", + "path": "/paths/~1unit~1conversion~1volume~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import create_payment_intent_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, PaymentIntent\nfrom kittycad.types import Response\n\n\ndef example_create_payment_intent_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[PaymentIntent, Error]\n ] = create_payment_intent_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: PaymentIntent = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.create_payment_intent_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_volume_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitVolumeConversion\nfrom kittycad.models.unit_volume import UnitVolume\nfrom kittycad.types import Response\n\n\ndef example_get_volume_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitVolumeConversion, Error]\n ] = get_volume_unit_conversion.sync(\n client=client,\n input_unit=UnitVolume.CM3,\n output_unit=UnitVolume.CM3,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitVolumeConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_volume_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1user~1extended/get/x-python", + "path": "/paths/~1unit~1conversion~1mass~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_self_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUser\nfrom kittycad.types import Response\n\n\ndef example_get_user_self_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ExtendedUser, Error]] = get_user_self_extended.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUser = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_self_extended.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_mass_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitMassConversion\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_get_mass_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitMassConversion, Error]\n ] = get_mass_unit_conversion.sync(\n client=client,\n input_unit=UnitMass.G,\n output_unit=UnitMass.G,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitMassConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_mass_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1users-extended~1{id}/get/x-python", + "path": "/paths/~1user~1api-calls/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUser\nfrom kittycad.types import Response\n\n\ndef example_get_user_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ExtendedUser, Error]] = get_user_extended.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUser = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_extended.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import user_list_api_calls\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_user_list_api_calls():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = user_list_api_calls.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.user_list_api_calls.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1mass~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1users~1{id}~1api-calls/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_mass_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitMassConversion\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_get_mass_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitMassConversion, Error]\n ] = get_mass_unit_conversion.sync(\n client=client,\n input_unit=UnitMass.G,\n output_unit=UnitMass.G,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitMassConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_mass_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_api_calls_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPriceResultsPage, Error\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_api_calls_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[ApiCallWithPriceResultsPage, Error]\n ] = list_api_calls_for_user.sync(\n client=client,\n id=\"\",\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPriceResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_api_calls_for_user.html" + } + }, + { + "op": "add", + "path": "/paths/~1user~1api-calls~1{id}/get/x-python", + "value": { + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallWithPrice, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_call_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiCallWithPrice, Error]] = get_api_call_for_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiCallWithPrice = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call_for_user.html" + } + }, + { + "op": "add", + "path": "/paths/~1file~1surface-area/post/x-python", + "value": { + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_surface_area\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileSurfaceArea\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_area import UnitArea\nfrom kittycad.types import Response\n\n\ndef example_create_file_surface_area():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[FileSurfaceArea, Error]\n ] = create_file_surface_area.sync(\n client=client,\n output_unit=UnitArea.CM2,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileSurfaceArea = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_surface_area.html" + } + }, + { + "op": "add", + "path": "/paths/~1unit~1conversion~1pressure~1{input_unit}~1{output_unit}/get/x-python", + "value": { + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_pressure_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitPressureConversion\nfrom kittycad.models.unit_pressure import UnitPressure\nfrom kittycad.types import Response\n\n\ndef example_get_pressure_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitPressureConversion, Error]\n ] = get_pressure_unit_conversion.sync(\n client=client,\n input_unit=UnitPressure.ATMOSPHERES,\n output_unit=UnitPressure.ATMOSPHERES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitPressureConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_pressure_unit_conversion.html" + } + }, + { + "op": "add", + "path": "/paths/~1async~1operations/get/x-python", + "value": { + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import list_async_operations\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AsyncApiCallResultsPage, Error\nfrom kittycad.models.api_call_status import ApiCallStatus\nfrom kittycad.models.created_at_sort_mode import CreatedAtSortMode\nfrom kittycad.types import Response\n\n\ndef example_list_async_operations():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[AsyncApiCallResultsPage, Error]\n ] = list_async_operations.sync(\n client=client,\n sort_by=CreatedAtSortMode.CREATED_AT_ASCENDING,\n status=ApiCallStatus.QUEUED,\n limit=None, # Optional[int]\n page_token=None, # Optional[str]\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AsyncApiCallResultsPage = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.list_async_operations.html" } }, { @@ -441,50 +433,50 @@ }, { "op": "add", - "path": "/paths/~1unit~1conversion~1volume~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1user~1payment~1invoices/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_volume_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitVolumeConversion\nfrom kittycad.models.unit_volume import UnitVolume\nfrom kittycad.types import Response\n\n\ndef example_get_volume_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitVolumeConversion, Error]\n ] = get_volume_unit_conversion.sync(\n client=client,\n input_unit=UnitVolume.CM3,\n output_unit=UnitVolume.CM3,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitVolumeConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_volume_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import list_invoices_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Invoice\nfrom kittycad.types import Response\n\n\ndef example_list_invoices_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[List[Invoice], Error]] = list_invoices_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[Invoice] = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.list_invoices_for_user.html" } }, { "op": "add", - "path": "/paths/~1user~1front-hash/get/x-python", + "path": "/paths/~1ai~1text-to-3d~1{output_format}/post/x-python", "value": { - "example": "from kittycad.api.users import get_user_front_hash_self\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_get_user_front_hash_self():\n # Create our client.\n client = ClientFromEnv()\n\n get_user_front_hash_self.sync(\n client=client,\n )\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_front_hash_self.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.ai import create_text_to_3d\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Mesh\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.types import Response\n\n\ndef example_create_text_to_3d():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Mesh, Error]] = create_text_to_3d.sync(\n client=client,\n output_format=FileExportFormat.FBX,\n prompt=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Mesh = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.ai.create_text_to_3d.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1power~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1ping/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_power_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitPowerConversion\nfrom kittycad.models.unit_power import UnitPower\nfrom kittycad.types import Response\n\n\ndef example_get_power_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitPowerConversion, Error]\n ] = get_power_unit_conversion.sync(\n client=client,\n input_unit=UnitPower.BTU_PER_MINUTE,\n output_unit=UnitPower.BTU_PER_MINUTE,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitPowerConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_power_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import ping\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Pong\nfrom kittycad.types import Response\n\n\ndef example_ping():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Pong, Error]] = ping.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Pong = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.ping.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1force~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1unit~1conversion~1temperature~1{input_unit}~1{output_unit}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_force_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitForceConversion\nfrom kittycad.models.unit_force import UnitForce\nfrom kittycad.types import Response\n\n\ndef example_get_force_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitForceConversion, Error]\n ] = get_force_unit_conversion.sync(\n client=client,\n input_unit=UnitForce.DYNES,\n output_unit=UnitForce.DYNES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitForceConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_force_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_temperature_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitTemperatureConversion\nfrom kittycad.models.unit_temperature import UnitTemperature\nfrom kittycad.types import Response\n\n\ndef example_get_temperature_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitTemperatureConversion, Error]\n ] = get_temperature_unit_conversion.sync(\n client=client,\n input_unit=UnitTemperature.CELSIUS,\n output_unit=UnitTemperature.CELSIUS,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitTemperatureConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_temperature_unit_conversion.html" } }, { "op": "add", - "path": "/paths/~1user~1api-tokens~1{token}/delete/x-python", + "path": "/paths/~1apps~1github~1callback/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import delete_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_delete_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = delete_api_token_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.delete_api_token_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.apps import apps_github_callback\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_apps_github_callback():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = apps_github_callback.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.apps.apps_github_callback.html" } }, { "op": "add", - "path": "/paths/~1user~1api-tokens~1{token}/get/x-python", + "path": "/paths/~1file~1density/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_tokens import get_api_token_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiToken, Error\nfrom kittycad.types import Response\n\n\ndef example_get_api_token_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ApiToken, Error]] = get_api_token_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ApiToken = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_tokens.get_api_token_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_density\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileDensity\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.models.unit_density import UnitDensity\nfrom kittycad.models.unit_mass import UnitMass\nfrom kittycad.types import Response\n\n\ndef example_create_file_density():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileDensity, Error]] = create_file_density.sync(\n client=client,\n material_mass=3.14,\n material_mass_unit=UnitMass.G,\n output_unit=UnitDensity.LB_FT3,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileDensity = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_density.html" } }, { @@ -497,58 +489,66 @@ }, { "op": "add", - "path": "/paths/~1ws~1executor~1term/get/x-python", + "path": "/paths/~1user~1session~1{token}/get/x-python", "value": { - "example": "from kittycad.api.executor import create_executor_term\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.types import Response\n\n\ndef example_create_executor_term():\n # Create our client.\n client = ClientFromEnv()\n\n # Connect to the websocket.\n websocket = create_executor_term.sync(\n client=client,\n )\n\n # Send a message.\n websocket.send(\"{}\")\n\n # Get the messages.\n for message in websocket:\n print(message)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.executor.create_executor_term.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_session_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, Session\nfrom kittycad.types import Response\n\n\ndef example_get_session_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[Session, Error]] = get_session_for_user.sync(\n client=client,\n token=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Session = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_session_for_user.html" } }, { "op": "add", - "path": "/paths/~1user~1payment~1balance/get/x-python", + "path": "/paths/~1file~1conversion~1{src_format}~1{output_format}/post/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import get_payment_balance_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import CustomerBalance, Error\nfrom kittycad.types import Response\n\n\ndef example_get_payment_balance_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[CustomerBalance, Error]\n ] = get_payment_balance_for_user.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: CustomerBalance = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.get_payment_balance_for_user.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.file import create_file_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, FileConversion\nfrom kittycad.models.file_export_format import FileExportFormat\nfrom kittycad.models.file_import_format import FileImportFormat\nfrom kittycad.types import Response\n\n\ndef example_create_file_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[FileConversion, Error]] = create_file_conversion.sync(\n client=client,\n output_format=FileExportFormat.FBX,\n src_format=FileImportFormat.FBX,\n body=bytes(\"some bytes\", \"utf-8\"),\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: FileConversion = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.file.create_file_conversion.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1energy~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1users~1{id}/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_energy_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitEnergyConversion\nfrom kittycad.models.unit_energy import UnitEnergy\nfrom kittycad.types import Response\n\n\ndef example_get_energy_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitEnergyConversion, Error]\n ] = get_energy_unit_conversion.sync(\n client=client,\n input_unit=UnitEnergy.BTU,\n output_unit=UnitEnergy.BTU,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitEnergyConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_energy_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, User\nfrom kittycad.types import Response\n\n\ndef example_get_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[User, Error]] = get_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: User = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user.html" } }, { "op": "add", - "path": "/paths/~1api-call-metrics/get/x-python", + "path": "/paths/~1.well-known~1ai-plugin.json/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.api_calls import get_api_call_metrics\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import ApiCallQueryGroup, Error\nfrom kittycad.models.api_call_query_group_by import ApiCallQueryGroupBy\nfrom kittycad.types import Response\n\n\ndef example_get_api_call_metrics():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[List[ApiCallQueryGroup], Error]\n ] = get_api_call_metrics.sync(\n client=client,\n group_by=ApiCallQueryGroupBy.EMAIL,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: List[ApiCallQueryGroup] = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.api_calls.get_api_call_metrics.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.meta import get_ai_plugin_manifest\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import AiPluginManifest, Error\nfrom kittycad.types import Response\n\n\ndef example_get_ai_plugin_manifest():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[AiPluginManifest, Error]\n ] = get_ai_plugin_manifest.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: AiPluginManifest = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.meta.get_ai_plugin_manifest.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1pressure~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1ws~1modeling~1commands/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_pressure_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitPressureConversion\nfrom kittycad.models.unit_pressure import UnitPressure\nfrom kittycad.types import Response\n\n\ndef example_get_pressure_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitPressureConversion, Error]\n ] = get_pressure_unit_conversion.sync(\n client=client,\n input_unit=UnitPressure.ATMOSPHERES,\n output_unit=UnitPressure.ATMOSPHERES,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitPressureConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_pressure_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.modeling import modeling_commands_ws\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, WebSocketResponse\nfrom kittycad.models.rtc_sdp_type import RtcSdpType\nfrom kittycad.models.rtc_session_description import RtcSessionDescription\nfrom kittycad.models.web_socket_request import sdp_offer\nfrom kittycad.types import Response\n\n\ndef example_modeling_commands_ws():\n # Create our client.\n client = ClientFromEnv()\n\n # Connect to the websocket.\n websocket = modeling_commands_ws.sync(\n client=client,\n fps=10,\n unlocked_framerate=False,\n video_res_height=10,\n video_res_width=10,\n webrtc=False,\n body=sdp_offer(\n offer=RtcSessionDescription(\n sdp=\"\",\n type=RtcSdpType.UNSPECIFIED,\n ),\n ),\n )\n\n # Send a message.\n websocket.send(\"{}\")\n\n # Get the messages.\n for message in websocket:\n print(message)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.modeling.modeling_commands_ws.html" } }, { "op": "add", - "path": "/paths/~1unit~1conversion~1frequency~1{input_unit}~1{output_unit}/get/x-python", + "path": "/paths/~1user~1extended/get/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.unit import get_frequency_unit_conversion\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, UnitFrequencyConversion\nfrom kittycad.models.unit_frequency import UnitFrequency\nfrom kittycad.types import Response\n\n\ndef example_get_frequency_unit_conversion():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[\n Union[UnitFrequencyConversion, Error]\n ] = get_frequency_unit_conversion.sync(\n client=client,\n input_unit=UnitFrequency.GIGAHERTZ,\n output_unit=UnitFrequency.GIGAHERTZ,\n value=3.14,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: UnitFrequencyConversion = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.unit.get_frequency_unit_conversion.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.users import get_user_self_extended\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error, ExtendedUser\nfrom kittycad.types import Response\n\n\ndef example_get_user_self_extended():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Union[ExtendedUser, Error]] = get_user_self_extended.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: ExtendedUser = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.users.get_user_self_extended.html" } }, { "op": "add", - "path": "/paths/~1logout/post/x-python", + "path": "/paths/~1user~1payment~1methods~1{id}/delete/x-python", "value": { - "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.hidden import logout\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_logout():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = logout.sync(\n client=client,\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", - "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.hidden.logout.html" + "example": "from typing import Any, List, Optional, Tuple, Union\n\nfrom kittycad.api.payments import delete_payment_method_for_user\nfrom kittycad.client import ClientFromEnv\nfrom kittycad.models import Error\nfrom kittycad.types import Response\n\n\ndef example_delete_payment_method_for_user():\n # Create our client.\n client = ClientFromEnv()\n\n result: Optional[Error] = delete_payment_method_for_user.sync(\n client=client,\n id=\"\",\n )\n\n if isinstance(result, Error) or result == None:\n print(result)\n raise Exception(\"Error in response\")\n\n body: Error = result\n print(body)\n", + "libDocsLink": "https://python.api.docs.kittycad.io/_autosummary/kittycad.api.payments.delete_payment_method_for_user.html" + } + }, + { + "op": "add", + "path": "/info/x-python", + "value": { + "client": "# Create a client with your token.\nfrom kittycad import Client\n\nclient = Client(token=\"$TOKEN\")\n\n# - OR -\n\n# Create a new client with your token parsed from the environment variable:\n# `KITTYCAD_API_TOKEN`.\nfrom kittycad import ClientFromEnv\n\nclient = ClientFromEnv()\n\n# NOTE: The python library additionally implements asyncio, however all the code samples we\n# show below use the sync functions for ease of use and understanding.\n# Check out the library docs at:\n# https://python.api.docs.kittycad.io/_autosummary/kittycad.api.html#module-kittycad.api\n# for more details.", + "install": "pip install kittycad" } } ] \ No newline at end of file diff --git a/kittycad/api/modeling/modeling_commands_ws.py b/kittycad/api/modeling/modeling_commands_ws.py index 7067b6d86..b422b011a 100644 --- a/kittycad/api/modeling/modeling_commands_ws.py +++ b/kittycad/api/modeling/modeling_commands_ws.py @@ -5,6 +5,7 @@ from ...client import Client from ...models.error import Error +from ...models.web_socket_request import WebSocketRequest def _get_kwargs( @@ -29,6 +30,10 @@ def _get_kwargs( webrtc: bool, + + body: WebSocketRequest, + + *, client: Client, @@ -42,6 +47,8 @@ def _get_kwargs( + + ) -> Dict[str, Any]: url = "{}/ws/modeling/commands".format(client.base_url) # noqa: E501 @@ -85,6 +92,8 @@ def _get_kwargs( url = url + "?webrtc=" + str(webrtc) + + headers: Dict[str, Any] = client.get_headers() @@ -95,7 +104,7 @@ def _get_kwargs( "headers": headers, "cookies": cookies, "timeout": client.get_timeout(), - + "content": body, } @@ -121,6 +130,10 @@ def sync( webrtc: bool, + + body: WebSocketRequest, + + *, client: Client, @@ -134,6 +147,8 @@ def sync( + + ) -> ClientConnection: """Pass those commands to the engine via websocket, and pass responses back to the client. Basically, this is a websocket proxy between the frontend/client and the engine.""" # noqa: E501 @@ -149,6 +164,8 @@ def sync( webrtc=webrtc, + body=body, + client=client, ) @@ -182,6 +199,10 @@ async def asyncio( webrtc: bool, + + body: WebSocketRequest, + + *, client: Client, @@ -195,6 +216,8 @@ async def asyncio( + + ) -> WebSocketClientProtocol: """Pass those commands to the engine via websocket, and pass responses back to the client. Basically, this is a websocket proxy between the frontend/client and the engine.""" # noqa: E501 @@ -210,6 +233,8 @@ async def asyncio( webrtc=webrtc, + body=body, + client=client, ) diff --git a/kittycad/examples_test.py b/kittycad/examples_test.py index 4babc23e9..f35eef00e 100644 --- a/kittycad/examples_test.py +++ b/kittycad/examples_test.py @@ -138,6 +138,8 @@ from kittycad.models.file_export_format import FileExportFormat from kittycad.models.file_import_format import FileImportFormat from kittycad.models.image_type import ImageType +from kittycad.models.rtc_sdp_type import RtcSdpType +from kittycad.models.rtc_session_description import RtcSessionDescription from kittycad.models.unit_angle import UnitAngle from kittycad.models.unit_area import UnitArea from kittycad.models.unit_current import UnitCurrent @@ -153,6 +155,7 @@ from kittycad.models.unit_torque import UnitTorque from kittycad.models.unit_volume import UnitVolume from kittycad.models.update_user import UpdateUser +from kittycad.models.web_socket_request import sdp_offer from kittycad.types import Response @@ -2197,45 +2200,6 @@ async def test_get_volume_unit_conversion_async(): ) -@pytest.mark.skip -def test_delete_user_self(): - # Create our client. - client = ClientFromEnv() - - result: Optional[Error] = delete_user_self.sync( - client=client, - ) - - if isinstance(result, Error) or result is None: - print(result) - raise Exception("Error in response") - - body: Error = result - print(body) - - # OR if you need more info (e.g. status_code) - response: Response[Optional[Error]] = delete_user_self.sync_detailed( - client=client, - ) - - -# OR run async -@pytest.mark.asyncio -@pytest.mark.skip -async def test_delete_user_self_async(): - # Create our client. - client = ClientFromEnv() - - result: Optional[Error] = await delete_user_self.asyncio( - client=client, - ) - - # OR run async with more info - response: Response[Optional[Error]] = await delete_user_self.asyncio_detailed( - client=client, - ) - - @pytest.mark.skip def test_get_user_self(): # Create our client. @@ -2350,6 +2314,45 @@ async def test_update_user_self_async(): ) +@pytest.mark.skip +def test_delete_user_self(): + # Create our client. + client = ClientFromEnv() + + result: Optional[Error] = delete_user_self.sync( + client=client, + ) + + if isinstance(result, Error) or result is None: + print(result) + raise Exception("Error in response") + + body: Error = result + print(body) + + # OR if you need more info (e.g. status_code) + response: Response[Optional[Error]] = delete_user_self.sync_detailed( + client=client, + ) + + +# OR run async +@pytest.mark.asyncio +@pytest.mark.skip +async def test_delete_user_self_async(): + # Create our client. + client = ClientFromEnv() + + result: Optional[Error] = await delete_user_self.asyncio( + client=client, + ) + + # OR run async with more info + response: Response[Optional[Error]] = await delete_user_self.asyncio_detailed( + client=client, + ) + + @pytest.mark.skip def test_user_list_api_calls(): # Create our client. @@ -2559,11 +2562,11 @@ async def test_create_api_token_for_user_async(): @pytest.mark.skip -def test_delete_api_token_for_user(): +def test_get_api_token_for_user(): # Create our client. client = ClientFromEnv() - result: Optional[Error] = delete_api_token_for_user.sync( + result: Optional[Union[ApiToken, Error]] = get_api_token_for_user.sync( client=client, token="", ) @@ -2572,11 +2575,13 @@ def test_delete_api_token_for_user(): print(result) raise Exception("Error in response") - body: Error = result + body: ApiToken = result print(body) # OR if you need more info (e.g. status_code) - response: Response[Optional[Error]] = delete_api_token_for_user.sync_detailed( + response: Response[ + Optional[Union[ApiToken, Error]] + ] = get_api_token_for_user.sync_detailed( client=client, token="", ) @@ -2585,30 +2590,30 @@ def test_delete_api_token_for_user(): # OR run async @pytest.mark.asyncio @pytest.mark.skip -async def test_delete_api_token_for_user_async(): +async def test_get_api_token_for_user_async(): # Create our client. client = ClientFromEnv() - result: Optional[Error] = await delete_api_token_for_user.asyncio( + result: Optional[Union[ApiToken, Error]] = await get_api_token_for_user.asyncio( client=client, token="", ) # OR run async with more info response: Response[ - Optional[Error] - ] = await delete_api_token_for_user.asyncio_detailed( + Optional[Union[ApiToken, Error]] + ] = await get_api_token_for_user.asyncio_detailed( client=client, token="", ) @pytest.mark.skip -def test_get_api_token_for_user(): +def test_delete_api_token_for_user(): # Create our client. client = ClientFromEnv() - result: Optional[Union[ApiToken, Error]] = get_api_token_for_user.sync( + result: Optional[Error] = delete_api_token_for_user.sync( client=client, token="", ) @@ -2617,13 +2622,11 @@ def test_get_api_token_for_user(): print(result) raise Exception("Error in response") - body: ApiToken = result + body: Error = result print(body) # OR if you need more info (e.g. status_code) - response: Response[ - Optional[Union[ApiToken, Error]] - ] = get_api_token_for_user.sync_detailed( + response: Response[Optional[Error]] = delete_api_token_for_user.sync_detailed( client=client, token="", ) @@ -2632,19 +2635,19 @@ def test_get_api_token_for_user(): # OR run async @pytest.mark.asyncio @pytest.mark.skip -async def test_get_api_token_for_user_async(): +async def test_delete_api_token_for_user_async(): # Create our client. client = ClientFromEnv() - result: Optional[Union[ApiToken, Error]] = await get_api_token_for_user.asyncio( + result: Optional[Error] = await delete_api_token_for_user.asyncio( client=client, token="", ) # OR run async with more info response: Response[ - Optional[Union[ApiToken, Error]] - ] = await get_api_token_for_user.asyncio_detailed( + Optional[Error] + ] = await delete_api_token_for_user.asyncio_detailed( client=client, token="", ) @@ -2769,11 +2772,11 @@ async def test_get_user_onboarding_self_async(): @pytest.mark.skip -def test_delete_payment_information_for_user(): +def test_get_payment_information_for_user(): # Create our client. client = ClientFromEnv() - result: Optional[Error] = delete_payment_information_for_user.sync( + result: Optional[Union[Customer, Error]] = get_payment_information_for_user.sync( client=client, ) @@ -2781,13 +2784,13 @@ def test_delete_payment_information_for_user(): print(result) raise Exception("Error in response") - body: Error = result + body: Customer = result print(body) # OR if you need more info (e.g. status_code) response: Response[ - Optional[Error] - ] = delete_payment_information_for_user.sync_detailed( + Optional[Union[Customer, Error]] + ] = get_payment_information_for_user.sync_detailed( client=client, ) @@ -2795,29 +2798,35 @@ def test_delete_payment_information_for_user(): # OR run async @pytest.mark.asyncio @pytest.mark.skip -async def test_delete_payment_information_for_user_async(): +async def test_get_payment_information_for_user_async(): # Create our client. client = ClientFromEnv() - result: Optional[Error] = await delete_payment_information_for_user.asyncio( + result: Optional[ + Union[Customer, Error] + ] = await get_payment_information_for_user.asyncio( client=client, ) # OR run async with more info response: Response[ - Optional[Error] - ] = await delete_payment_information_for_user.asyncio_detailed( + Optional[Union[Customer, Error]] + ] = await get_payment_information_for_user.asyncio_detailed( client=client, ) @pytest.mark.skip -def test_get_payment_information_for_user(): +def test_update_payment_information_for_user(): # Create our client. client = ClientFromEnv() - result: Optional[Union[Customer, Error]] = get_payment_information_for_user.sync( + result: Optional[Union[Customer, Error]] = update_payment_information_for_user.sync( client=client, + body=BillingInfo( + name="", + phone="", + ), ) if isinstance(result, Error) or result is None: @@ -2830,29 +2839,41 @@ def test_get_payment_information_for_user(): # OR if you need more info (e.g. status_code) response: Response[ Optional[Union[Customer, Error]] - ] = get_payment_information_for_user.sync_detailed( + ] = update_payment_information_for_user.sync_detailed( client=client, + body=BillingInfo( + name="", + phone="", + ), ) # OR run async @pytest.mark.asyncio @pytest.mark.skip -async def test_get_payment_information_for_user_async(): +async def test_update_payment_information_for_user_async(): # Create our client. client = ClientFromEnv() result: Optional[ Union[Customer, Error] - ] = await get_payment_information_for_user.asyncio( + ] = await update_payment_information_for_user.asyncio( client=client, + body=BillingInfo( + name="", + phone="", + ), ) # OR run async with more info response: Response[ Optional[Union[Customer, Error]] - ] = await get_payment_information_for_user.asyncio_detailed( + ] = await update_payment_information_for_user.asyncio_detailed( client=client, + body=BillingInfo( + name="", + phone="", + ), ) @@ -2918,63 +2939,45 @@ async def test_create_payment_information_for_user_async(): @pytest.mark.skip -def test_update_payment_information_for_user(): +def test_delete_payment_information_for_user(): # Create our client. client = ClientFromEnv() - result: Optional[Union[Customer, Error]] = update_payment_information_for_user.sync( + result: Optional[Error] = delete_payment_information_for_user.sync( client=client, - body=BillingInfo( - name="", - phone="", - ), ) if isinstance(result, Error) or result is None: print(result) raise Exception("Error in response") - body: Customer = result + body: Error = result print(body) # OR if you need more info (e.g. status_code) response: Response[ - Optional[Union[Customer, Error]] - ] = update_payment_information_for_user.sync_detailed( + Optional[Error] + ] = delete_payment_information_for_user.sync_detailed( client=client, - body=BillingInfo( - name="", - phone="", - ), ) # OR run async @pytest.mark.asyncio @pytest.mark.skip -async def test_update_payment_information_for_user_async(): +async def test_delete_payment_information_for_user_async(): # Create our client. client = ClientFromEnv() - result: Optional[ - Union[Customer, Error] - ] = await update_payment_information_for_user.asyncio( + result: Optional[Error] = await delete_payment_information_for_user.asyncio( client=client, - body=BillingInfo( - name="", - phone="", - ), ) # OR run async with more info response: Response[ - Optional[Union[Customer, Error]] - ] = await update_payment_information_for_user.asyncio_detailed( + Optional[Error] + ] = await delete_payment_information_for_user.asyncio_detailed( client=client, - body=BillingInfo( - name="", - phone="", - ), ) @@ -3611,6 +3614,12 @@ def test_modeling_commands_ws(): video_res_height=10, video_res_width=10, webrtc=False, + body=sdp_offer( + offer=RtcSessionDescription( + sdp="", + type=RtcSdpType.UNSPECIFIED, + ), + ), ) # Send a message. @@ -3636,6 +3645,12 @@ async def test_modeling_commands_ws_async(): video_res_height=10, video_res_width=10, webrtc=False, + body=sdp_offer( + offer=RtcSessionDescription( + sdp="", + type=RtcSdpType.UNSPECIFIED, + ), + ), ) # Send a message. diff --git a/kittycad/models/__init__.py b/kittycad/models/__init__.py index d3f16ba19..11b9e3d55 100644 --- a/kittycad/models/__init__.py +++ b/kittycad/models/__init__.py @@ -85,6 +85,7 @@ from .file_volume import FileVolume from .gateway import Gateway from .get_entity_type import GetEntityType +from .get_sketch_mode_plane import GetSketchModePlane from .gltf_presentation import GltfPresentation from .gltf_storage import GltfStorage from .highlight_set_entity import HighlightSetEntity diff --git a/kittycad/models/get_sketch_mode_plane.py b/kittycad/models/get_sketch_mode_plane.py new file mode 100644 index 000000000..2ffbfcd2a --- /dev/null +++ b/kittycad/models/get_sketch_mode_plane.py @@ -0,0 +1,87 @@ +from typing import Any, Dict, List, Type, TypeVar, Union + +import attr + +from ..models.point3d import Point3d +from ..types import UNSET, Unset + +QI = TypeVar("QI", bound="GetSketchModePlane") + +@attr.s(auto_attribs=True) +class GetSketchModePlane: + """ The plane for sketch mode. """ # noqa: E501 + x_axis: Union[Unset, Point3d] = UNSET + y_axis: Union[Unset, Point3d] = UNSET + z_axis: Union[Unset, Point3d] = UNSET + + additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict) + + def to_dict(self) -> Dict[str, Any]: + if not isinstance(self.x_axis, Unset): + x_axis = self.x_axis + if not isinstance(self.y_axis, Unset): + y_axis = self.y_axis + if not isinstance(self.z_axis, Unset): + z_axis = self.z_axis + + field_dict: Dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update({}) + if x_axis is not UNSET: + field_dict['x_axis'] = x_axis + if y_axis is not UNSET: + field_dict['y_axis'] = y_axis + if z_axis is not UNSET: + field_dict['z_axis'] = z_axis + + return field_dict + + @classmethod + def from_dict(cls: Type[QI], src_dict: Dict[str, Any]) -> QI: + d = src_dict.copy() + _x_axis = d.pop("x_axis", UNSET) + x_axis: Union[Unset, Point3d] + if isinstance(_x_axis, Unset): + x_axis = UNSET + else: + x_axis = _x_axis # type: ignore[arg-type] + + _y_axis = d.pop("y_axis", UNSET) + y_axis: Union[Unset, Point3d] + if isinstance(_y_axis, Unset): + y_axis = UNSET + else: + y_axis = _y_axis # type: ignore[arg-type] + + _z_axis = d.pop("z_axis", UNSET) + z_axis: Union[Unset, Point3d] + if isinstance(_z_axis, Unset): + z_axis = UNSET + else: + z_axis = _z_axis # type: ignore[arg-type] + + + get_sketch_mode_plane = cls( + x_axis= x_axis, + y_axis= y_axis, + z_axis= z_axis, + ) + + get_sketch_mode_plane.additional_properties = d + return get_sketch_mode_plane + + @property + def additional_keys(self) -> List[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties diff --git a/kittycad/models/highlight_set_entity.py b/kittycad/models/highlight_set_entity.py index fa1c8b47b..45d06c38e 100644 --- a/kittycad/models/highlight_set_entity.py +++ b/kittycad/models/highlight_set_entity.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -QI = TypeVar("QI", bound="HighlightSetEntity") +TP = TypeVar("TP", bound="HighlightSetEntity") @attr.s(auto_attribs=True) class HighlightSetEntity: @@ -29,7 +29,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QI], src_dict: Dict[str, Any]) -> QI: + def from_dict(cls: Type[TP], src_dict: Dict[str, Any]) -> TP: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) diff --git a/kittycad/models/ice_server.py b/kittycad/models/ice_server.py index aab26a562..6168732fa 100644 --- a/kittycad/models/ice_server.py +++ b/kittycad/models/ice_server.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -TP = TypeVar("TP", bound="IceServer") +CF = TypeVar("CF", bound="IceServer") @attr.s(auto_attribs=True) class IceServer: @@ -35,7 +35,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TP], src_dict: Dict[str, Any]) -> TP: + def from_dict(cls: Type[CF], src_dict: Dict[str, Any]) -> CF: d = src_dict.copy() credential = d.pop("credential", UNSET) diff --git a/kittycad/models/import_file.py b/kittycad/models/import_file.py index b581a26ff..187ab0af1 100644 --- a/kittycad/models/import_file.py +++ b/kittycad/models/import_file.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -CF = TypeVar("CF", bound="ImportFile") +OM = TypeVar("OM", bound="ImportFile") @attr.s(auto_attribs=True) class ImportFile: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CF], src_dict: Dict[str, Any]) -> CF: + def from_dict(cls: Type[OM], src_dict: Dict[str, Any]) -> OM: d = src_dict.copy() data = cast(List[int], d.pop("data", UNSET)) diff --git a/kittycad/models/import_files.py b/kittycad/models/import_files.py index f78f2a422..d4383740d 100644 --- a/kittycad/models/import_files.py +++ b/kittycad/models/import_files.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -OM = TypeVar("OM", bound="ImportFiles") +EN = TypeVar("EN", bound="ImportFiles") @attr.s(auto_attribs=True) class ImportFiles: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OM], src_dict: Dict[str, Any]) -> OM: + def from_dict(cls: Type[EN], src_dict: Dict[str, Any]) -> EN: d = src_dict.copy() object_id = d.pop("object_id", UNSET) diff --git a/kittycad/models/input_format.py b/kittycad/models/input_format.py index 0ac4dafe3..44e10fbde 100644 --- a/kittycad/models/input_format.py +++ b/kittycad/models/input_format.py @@ -6,7 +6,7 @@ from ..models.unit_length import UnitLength from ..types import UNSET, Unset -EN = TypeVar("EN", bound="fbx") +RS = TypeVar("RS", bound="fbx") @attr.s(auto_attribs=True) class fbx: @@ -26,7 +26,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[EN], src_dict: Dict[str, Any]) -> EN: + def from_dict(cls: Type[RS], src_dict: Dict[str, Any]) -> RS: d = src_dict.copy() type = d.pop("type", UNSET) @@ -57,7 +57,7 @@ def __contains__(self, key: str) -> bool: -RS = TypeVar("RS", bound="gltf") +LR = TypeVar("LR", bound="gltf") @attr.s(auto_attribs=True) class gltf: @@ -77,7 +77,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RS], src_dict: Dict[str, Any]) -> RS: + def from_dict(cls: Type[LR], src_dict: Dict[str, Any]) -> LR: d = src_dict.copy() type = d.pop("type", UNSET) @@ -108,7 +108,7 @@ def __contains__(self, key: str) -> bool: -LR = TypeVar("LR", bound="obj") +MP = TypeVar("MP", bound="obj") @attr.s(auto_attribs=True) class obj: @@ -138,7 +138,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LR], src_dict: Dict[str, Any]) -> LR: + def from_dict(cls: Type[MP], src_dict: Dict[str, Any]) -> MP: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] @@ -185,7 +185,7 @@ def __contains__(self, key: str) -> bool: -MP = TypeVar("MP", bound="ply") +WF = TypeVar("WF", bound="ply") @attr.s(auto_attribs=True) class ply: @@ -215,7 +215,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MP], src_dict: Dict[str, Any]) -> MP: + def from_dict(cls: Type[WF], src_dict: Dict[str, Any]) -> WF: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] @@ -262,7 +262,7 @@ def __contains__(self, key: str) -> bool: -WF = TypeVar("WF", bound="sldprt") +RO = TypeVar("RO", bound="sldprt") @attr.s(auto_attribs=True) class sldprt: @@ -282,7 +282,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WF], src_dict: Dict[str, Any]) -> WF: + def from_dict(cls: Type[RO], src_dict: Dict[str, Any]) -> RO: d = src_dict.copy() type = d.pop("type", UNSET) @@ -313,7 +313,7 @@ def __contains__(self, key: str) -> bool: -RO = TypeVar("RO", bound="step") +DN = TypeVar("DN", bound="step") @attr.s(auto_attribs=True) class step: @@ -333,7 +333,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RO], src_dict: Dict[str, Any]) -> RO: + def from_dict(cls: Type[DN], src_dict: Dict[str, Any]) -> DN: d = src_dict.copy() type = d.pop("type", UNSET) @@ -364,7 +364,7 @@ def __contains__(self, key: str) -> bool: -DN = TypeVar("DN", bound="stl") +BA = TypeVar("BA", bound="stl") @attr.s(auto_attribs=True) class stl: @@ -394,7 +394,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DN], src_dict: Dict[str, Any]) -> DN: + def from_dict(cls: Type[BA], src_dict: Dict[str, Any]) -> BA: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] diff --git a/kittycad/models/invoice.py b/kittycad/models/invoice.py index 0123937b4..6550a811f 100644 --- a/kittycad/models/invoice.py +++ b/kittycad/models/invoice.py @@ -8,7 +8,7 @@ from ..models.invoice_status import InvoiceStatus from ..types import UNSET, Unset -BA = TypeVar("BA", bound="Invoice") +OR = TypeVar("OR", bound="Invoice") @attr.s(auto_attribs=True) class Invoice: @@ -138,7 +138,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BA], src_dict: Dict[str, Any]) -> BA: + def from_dict(cls: Type[OR], src_dict: Dict[str, Any]) -> OR: d = src_dict.copy() amount_due = d.pop("amount_due", UNSET) diff --git a/kittycad/models/invoice_line_item.py b/kittycad/models/invoice_line_item.py index 90757c0fe..56c058d18 100644 --- a/kittycad/models/invoice_line_item.py +++ b/kittycad/models/invoice_line_item.py @@ -5,7 +5,7 @@ from ..models.currency import Currency from ..types import UNSET, Unset -OR = TypeVar("OR", bound="InvoiceLineItem") +CB = TypeVar("CB", bound="InvoiceLineItem") @attr.s(auto_attribs=True) class InvoiceLineItem: @@ -48,7 +48,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OR], src_dict: Dict[str, Any]) -> OR: + def from_dict(cls: Type[CB], src_dict: Dict[str, Any]) -> CB: d = src_dict.copy() amount = d.pop("amount", UNSET) diff --git a/kittycad/models/jetstream.py b/kittycad/models/jetstream.py index b66eb5cb6..3c74582c9 100644 --- a/kittycad/models/jetstream.py +++ b/kittycad/models/jetstream.py @@ -7,7 +7,7 @@ from ..models.meta_cluster_info import MetaClusterInfo from ..types import UNSET, Unset -CB = TypeVar("CB", bound="Jetstream") +LC = TypeVar("LC", bound="Jetstream") @attr.s(auto_attribs=True) class Jetstream: @@ -39,7 +39,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CB], src_dict: Dict[str, Any]) -> CB: + def from_dict(cls: Type[LC], src_dict: Dict[str, Any]) -> LC: d = src_dict.copy() _config = d.pop("config", UNSET) config: Union[Unset, JetstreamConfig] diff --git a/kittycad/models/jetstream_api_stats.py b/kittycad/models/jetstream_api_stats.py index 7f88dd674..e58f73298 100644 --- a/kittycad/models/jetstream_api_stats.py +++ b/kittycad/models/jetstream_api_stats.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -LC = TypeVar("LC", bound="JetstreamApiStats") +TO = TypeVar("TO", bound="JetstreamApiStats") @attr.s(auto_attribs=True) class JetstreamApiStats: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LC], src_dict: Dict[str, Any]) -> LC: + def from_dict(cls: Type[TO], src_dict: Dict[str, Any]) -> TO: d = src_dict.copy() errors = d.pop("errors", UNSET) diff --git a/kittycad/models/jetstream_config.py b/kittycad/models/jetstream_config.py index 20a4b1001..7b9c2a600 100644 --- a/kittycad/models/jetstream_config.py +++ b/kittycad/models/jetstream_config.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -TO = TypeVar("TO", bound="JetstreamConfig") +ZP = TypeVar("ZP", bound="JetstreamConfig") @attr.s(auto_attribs=True) class JetstreamConfig: @@ -37,7 +37,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TO], src_dict: Dict[str, Any]) -> TO: + def from_dict(cls: Type[ZP], src_dict: Dict[str, Any]) -> ZP: d = src_dict.copy() domain = d.pop("domain", UNSET) diff --git a/kittycad/models/jetstream_stats.py b/kittycad/models/jetstream_stats.py index 9eeff5913..4fe25b270 100644 --- a/kittycad/models/jetstream_stats.py +++ b/kittycad/models/jetstream_stats.py @@ -5,7 +5,7 @@ from ..models.jetstream_api_stats import JetstreamApiStats from ..types import UNSET, Unset -ZP = TypeVar("ZP", bound="JetstreamStats") +EO = TypeVar("EO", bound="JetstreamStats") @attr.s(auto_attribs=True) class JetstreamStats: @@ -51,7 +51,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZP], src_dict: Dict[str, Any]) -> ZP: + def from_dict(cls: Type[EO], src_dict: Dict[str, Any]) -> EO: d = src_dict.copy() accounts = d.pop("accounts", UNSET) diff --git a/kittycad/models/leaf_node.py b/kittycad/models/leaf_node.py index 1e57fbc2d..2b2f225b4 100644 --- a/kittycad/models/leaf_node.py +++ b/kittycad/models/leaf_node.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -EO = TypeVar("EO", bound="LeafNode") +NY = TypeVar("NY", bound="LeafNode") @attr.s(auto_attribs=True) class LeafNode: @@ -37,7 +37,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[EO], src_dict: Dict[str, Any]) -> EO: + def from_dict(cls: Type[NY], src_dict: Dict[str, Any]) -> NY: d = src_dict.copy() auth_timeout = d.pop("auth_timeout", UNSET) diff --git a/kittycad/models/mass.py b/kittycad/models/mass.py index 8ac73f569..f4241937b 100644 --- a/kittycad/models/mass.py +++ b/kittycad/models/mass.py @@ -5,7 +5,7 @@ from ..models.unit_mass import UnitMass from ..types import UNSET, Unset -NY = TypeVar("NY", bound="Mass") +QO = TypeVar("QO", bound="Mass") @attr.s(auto_attribs=True) class Mass: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NY], src_dict: Dict[str, Any]) -> NY: + def from_dict(cls: Type[QO], src_dict: Dict[str, Any]) -> QO: d = src_dict.copy() mass = d.pop("mass", UNSET) diff --git a/kittycad/models/mesh.py b/kittycad/models/mesh.py index 2575cd48a..01f1bdf07 100644 --- a/kittycad/models/mesh.py +++ b/kittycad/models/mesh.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -QO = TypeVar("QO", bound="Mesh") +KX = TypeVar("KX", bound="Mesh") @attr.s(auto_attribs=True) class Mesh: @@ -24,7 +24,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QO], src_dict: Dict[str, Any]) -> QO: + def from_dict(cls: Type[KX], src_dict: Dict[str, Any]) -> KX: d = src_dict.copy() mesh = d.pop("mesh", UNSET) diff --git a/kittycad/models/meta_cluster_info.py b/kittycad/models/meta_cluster_info.py index a133f70c5..585814c31 100644 --- a/kittycad/models/meta_cluster_info.py +++ b/kittycad/models/meta_cluster_info.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -KX = TypeVar("KX", bound="MetaClusterInfo") +IZ = TypeVar("IZ", bound="MetaClusterInfo") @attr.s(auto_attribs=True) class MetaClusterInfo: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[KX], src_dict: Dict[str, Any]) -> KX: + def from_dict(cls: Type[IZ], src_dict: Dict[str, Any]) -> IZ: d = src_dict.copy() cluster_size = d.pop("cluster_size", UNSET) diff --git a/kittycad/models/metadata.py b/kittycad/models/metadata.py index 1c7e53b5f..5e15dfdff 100644 --- a/kittycad/models/metadata.py +++ b/kittycad/models/metadata.py @@ -9,7 +9,7 @@ from ..models.point_e_metadata import PointEMetadata from ..types import UNSET, Unset -IZ = TypeVar("IZ", bound="Metadata") +WO = TypeVar("WO", bound="Metadata") @attr.s(auto_attribs=True) class Metadata: @@ -57,7 +57,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[IZ], src_dict: Dict[str, Any]) -> IZ: + def from_dict(cls: Type[WO], src_dict: Dict[str, Any]) -> WO: d = src_dict.copy() _cache = d.pop("cache", UNSET) cache: Union[Unset, CacheMetadata] diff --git a/kittycad/models/modeling_cmd.py b/kittycad/models/modeling_cmd.py index 16bab619e..92e9c5172 100644 --- a/kittycad/models/modeling_cmd.py +++ b/kittycad/models/modeling_cmd.py @@ -21,7 +21,7 @@ from ..models.unit_volume import UnitVolume from ..types import UNSET, Unset -WO = TypeVar("WO", bound="start_path") +NK = TypeVar("NK", bound="start_path") @attr.s(auto_attribs=True) class start_path: @@ -41,7 +41,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WO], src_dict: Dict[str, Any]) -> WO: + def from_dict(cls: Type[NK], src_dict: Dict[str, Any]) -> NK: d = src_dict.copy() type = d.pop("type", UNSET) @@ -72,7 +72,7 @@ def __contains__(self, key: str) -> bool: -NK = TypeVar("NK", bound="move_path_pen") +UQ = TypeVar("UQ", bound="move_path_pen") @attr.s(auto_attribs=True) class move_path_pen: @@ -102,7 +102,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NK], src_dict: Dict[str, Any]) -> NK: + def from_dict(cls: Type[UQ], src_dict: Dict[str, Any]) -> UQ: d = src_dict.copy() _path = d.pop("path", UNSET) path: Union[Unset, ModelingCmdId] @@ -149,7 +149,7 @@ def __contains__(self, key: str) -> bool: -UQ = TypeVar("UQ", bound="extend_path") +QE = TypeVar("QE", bound="extend_path") @attr.s(auto_attribs=True) class extend_path: @@ -179,7 +179,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UQ], src_dict: Dict[str, Any]) -> UQ: + def from_dict(cls: Type[QE], src_dict: Dict[str, Any]) -> QE: d = src_dict.copy() _path = d.pop("path", UNSET) path: Union[Unset, ModelingCmdId] @@ -226,7 +226,7 @@ def __contains__(self, key: str) -> bool: -QE = TypeVar("QE", bound="extrude") +XH = TypeVar("XH", bound="extrude") @attr.s(auto_attribs=True) class extrude: @@ -259,7 +259,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QE], src_dict: Dict[str, Any]) -> QE: + def from_dict(cls: Type[XH], src_dict: Dict[str, Any]) -> XH: d = src_dict.copy() cap = d.pop("cap", UNSET) @@ -304,7 +304,7 @@ def __contains__(self, key: str) -> bool: -XH = TypeVar("XH", bound="close_path") +KT = TypeVar("KT", bound="close_path") @attr.s(auto_attribs=True) class close_path: @@ -328,7 +328,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[XH], src_dict: Dict[str, Any]) -> XH: + def from_dict(cls: Type[KT], src_dict: Dict[str, Any]) -> KT: d = src_dict.copy() path_id = d.pop("path_id", UNSET) @@ -362,7 +362,7 @@ def __contains__(self, key: str) -> bool: -KT = TypeVar("KT", bound="camera_drag_start") +BV = TypeVar("BV", bound="camera_drag_start") @attr.s(auto_attribs=True) class camera_drag_start: @@ -392,7 +392,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[KT], src_dict: Dict[str, Any]) -> KT: + def from_dict(cls: Type[BV], src_dict: Dict[str, Any]) -> BV: d = src_dict.copy() _interaction = d.pop("interaction", UNSET) interaction: Union[Unset, CameraDragInteractionType] @@ -439,7 +439,7 @@ def __contains__(self, key: str) -> bool: -BV = TypeVar("BV", bound="camera_drag_move") +GU = TypeVar("GU", bound="camera_drag_move") @attr.s(auto_attribs=True) class camera_drag_move: @@ -473,7 +473,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BV], src_dict: Dict[str, Any]) -> BV: + def from_dict(cls: Type[GU], src_dict: Dict[str, Any]) -> GU: d = src_dict.copy() _interaction = d.pop("interaction", UNSET) interaction: Union[Unset, CameraDragInteractionType] @@ -523,7 +523,7 @@ def __contains__(self, key: str) -> bool: -GU = TypeVar("GU", bound="camera_drag_end") +SS = TypeVar("SS", bound="camera_drag_end") @attr.s(auto_attribs=True) class camera_drag_end: @@ -553,7 +553,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GU], src_dict: Dict[str, Any]) -> GU: + def from_dict(cls: Type[SS], src_dict: Dict[str, Any]) -> SS: d = src_dict.copy() _interaction = d.pop("interaction", UNSET) interaction: Union[Unset, CameraDragInteractionType] @@ -600,7 +600,7 @@ def __contains__(self, key: str) -> bool: -SS = TypeVar("SS", bound="default_camera_look_at") +UP = TypeVar("UP", bound="default_camera_look_at") @attr.s(auto_attribs=True) class default_camera_look_at: @@ -635,7 +635,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SS], src_dict: Dict[str, Any]) -> SS: + def from_dict(cls: Type[UP], src_dict: Dict[str, Any]) -> UP: d = src_dict.copy() _center = d.pop("center", UNSET) center: Union[Unset, Point3d] @@ -690,7 +690,7 @@ def __contains__(self, key: str) -> bool: -UP = TypeVar("UP", bound="default_camera_zoom") +AZ = TypeVar("AZ", bound="default_camera_zoom") @attr.s(auto_attribs=True) class default_camera_zoom: @@ -714,7 +714,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UP], src_dict: Dict[str, Any]) -> UP: + def from_dict(cls: Type[AZ], src_dict: Dict[str, Any]) -> AZ: d = src_dict.copy() magnitude = d.pop("magnitude", UNSET) @@ -748,7 +748,7 @@ def __contains__(self, key: str) -> bool: -AZ = TypeVar("AZ", bound="default_camera_enable_sketch_mode") +DJ = TypeVar("DJ", bound="default_camera_enable_sketch_mode") @attr.s(auto_attribs=True) class default_camera_enable_sketch_mode: @@ -795,7 +795,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AZ], src_dict: Dict[str, Any]) -> AZ: + def from_dict(cls: Type[DJ], src_dict: Dict[str, Any]) -> DJ: d = src_dict.copy() animated = d.pop("animated", UNSET) @@ -859,7 +859,7 @@ def __contains__(self, key: str) -> bool: -DJ = TypeVar("DJ", bound="default_camera_disable_sketch_mode") +WJ = TypeVar("WJ", bound="default_camera_disable_sketch_mode") @attr.s(auto_attribs=True) class default_camera_disable_sketch_mode: @@ -879,7 +879,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DJ], src_dict: Dict[str, Any]) -> DJ: + def from_dict(cls: Type[WJ], src_dict: Dict[str, Any]) -> WJ: d = src_dict.copy() type = d.pop("type", UNSET) @@ -910,7 +910,7 @@ def __contains__(self, key: str) -> bool: -WJ = TypeVar("WJ", bound="export") +TR = TypeVar("TR", bound="export") @attr.s(auto_attribs=True) class export: @@ -946,7 +946,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WJ], src_dict: Dict[str, Any]) -> WJ: + def from_dict(cls: Type[TR], src_dict: Dict[str, Any]) -> TR: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -996,7 +996,7 @@ def __contains__(self, key: str) -> bool: -TR = TypeVar("TR", bound="entity_get_parent_id") +YD = TypeVar("YD", bound="entity_get_parent_id") @attr.s(auto_attribs=True) class entity_get_parent_id: @@ -1020,7 +1020,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TR], src_dict: Dict[str, Any]) -> TR: + def from_dict(cls: Type[YD], src_dict: Dict[str, Any]) -> YD: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) @@ -1054,7 +1054,7 @@ def __contains__(self, key: str) -> bool: -YD = TypeVar("YD", bound="entity_get_num_children") +JF = TypeVar("JF", bound="entity_get_num_children") @attr.s(auto_attribs=True) class entity_get_num_children: @@ -1078,7 +1078,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[YD], src_dict: Dict[str, Any]) -> YD: + def from_dict(cls: Type[JF], src_dict: Dict[str, Any]) -> JF: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) @@ -1112,7 +1112,7 @@ def __contains__(self, key: str) -> bool: -JF = TypeVar("JF", bound="entity_get_child_uuid") +VP = TypeVar("VP", bound="entity_get_child_uuid") @attr.s(auto_attribs=True) class entity_get_child_uuid: @@ -1140,7 +1140,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JF], src_dict: Dict[str, Any]) -> JF: + def from_dict(cls: Type[VP], src_dict: Dict[str, Any]) -> VP: d = src_dict.copy() child_index = d.pop("child_index", UNSET) @@ -1177,7 +1177,7 @@ def __contains__(self, key: str) -> bool: -VP = TypeVar("VP", bound="entity_get_all_child_uuids") +EL = TypeVar("EL", bound="entity_get_all_child_uuids") @attr.s(auto_attribs=True) class entity_get_all_child_uuids: @@ -1201,7 +1201,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VP], src_dict: Dict[str, Any]) -> VP: + def from_dict(cls: Type[EL], src_dict: Dict[str, Any]) -> EL: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) @@ -1235,7 +1235,7 @@ def __contains__(self, key: str) -> bool: -EL = TypeVar("EL", bound="edit_mode_enter") +ZG = TypeVar("ZG", bound="edit_mode_enter") @attr.s(auto_attribs=True) class edit_mode_enter: @@ -1259,7 +1259,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[EL], src_dict: Dict[str, Any]) -> EL: + def from_dict(cls: Type[ZG], src_dict: Dict[str, Any]) -> ZG: d = src_dict.copy() target = d.pop("target", UNSET) @@ -1293,7 +1293,7 @@ def __contains__(self, key: str) -> bool: -ZG = TypeVar("ZG", bound="edit_mode_exit") +LF = TypeVar("LF", bound="edit_mode_exit") @attr.s(auto_attribs=True) class edit_mode_exit: @@ -1313,7 +1313,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZG], src_dict: Dict[str, Any]) -> ZG: + def from_dict(cls: Type[LF], src_dict: Dict[str, Any]) -> LF: d = src_dict.copy() type = d.pop("type", UNSET) @@ -1344,7 +1344,7 @@ def __contains__(self, key: str) -> bool: -LF = TypeVar("LF", bound="select_with_point") +CS = TypeVar("CS", bound="select_with_point") @attr.s(auto_attribs=True) class select_with_point: @@ -1374,7 +1374,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LF], src_dict: Dict[str, Any]) -> LF: + def from_dict(cls: Type[CS], src_dict: Dict[str, Any]) -> CS: d = src_dict.copy() _selected_at_window = d.pop("selected_at_window", UNSET) selected_at_window: Union[Unset, Point2d] @@ -1421,7 +1421,7 @@ def __contains__(self, key: str) -> bool: -CS = TypeVar("CS", bound="select_clear") +GN = TypeVar("GN", bound="select_clear") @attr.s(auto_attribs=True) class select_clear: @@ -1441,7 +1441,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CS], src_dict: Dict[str, Any]) -> CS: + def from_dict(cls: Type[GN], src_dict: Dict[str, Any]) -> GN: d = src_dict.copy() type = d.pop("type", UNSET) @@ -1472,7 +1472,7 @@ def __contains__(self, key: str) -> bool: -GN = TypeVar("GN", bound="select_add") +GD = TypeVar("GD", bound="select_add") @attr.s(auto_attribs=True) class select_add: @@ -1498,7 +1498,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GN], src_dict: Dict[str, Any]) -> GN: + def from_dict(cls: Type[GD], src_dict: Dict[str, Any]) -> GD: d = src_dict.copy() entities = cast(List[str], d.pop("entities", UNSET)) @@ -1532,7 +1532,7 @@ def __contains__(self, key: str) -> bool: -GD = TypeVar("GD", bound="select_remove") +VJ = TypeVar("VJ", bound="select_remove") @attr.s(auto_attribs=True) class select_remove: @@ -1558,7 +1558,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GD], src_dict: Dict[str, Any]) -> GD: + def from_dict(cls: Type[VJ], src_dict: Dict[str, Any]) -> VJ: d = src_dict.copy() entities = cast(List[str], d.pop("entities", UNSET)) @@ -1592,7 +1592,7 @@ def __contains__(self, key: str) -> bool: -VJ = TypeVar("VJ", bound="select_replace") +OX = TypeVar("OX", bound="select_replace") @attr.s(auto_attribs=True) class select_replace: @@ -1618,7 +1618,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VJ], src_dict: Dict[str, Any]) -> VJ: + def from_dict(cls: Type[OX], src_dict: Dict[str, Any]) -> OX: d = src_dict.copy() entities = cast(List[str], d.pop("entities", UNSET)) @@ -1652,7 +1652,7 @@ def __contains__(self, key: str) -> bool: -OX = TypeVar("OX", bound="select_get") +YW = TypeVar("YW", bound="select_get") @attr.s(auto_attribs=True) class select_get: @@ -1672,7 +1672,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OX], src_dict: Dict[str, Any]) -> OX: + def from_dict(cls: Type[YW], src_dict: Dict[str, Any]) -> YW: d = src_dict.copy() type = d.pop("type", UNSET) @@ -1703,7 +1703,7 @@ def __contains__(self, key: str) -> bool: -YW = TypeVar("YW", bound="highlight_set_entity") +QX = TypeVar("QX", bound="highlight_set_entity") @attr.s(auto_attribs=True) class highlight_set_entity: @@ -1732,7 +1732,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[YW], src_dict: Dict[str, Any]) -> YW: + def from_dict(cls: Type[QX], src_dict: Dict[str, Any]) -> QX: d = src_dict.copy() _selected_at_window = d.pop("selected_at_window", UNSET) selected_at_window: Union[Unset, Point2d] @@ -1774,7 +1774,7 @@ def __contains__(self, key: str) -> bool: -QX = TypeVar("QX", bound="highlight_set_entities") +NO = TypeVar("NO", bound="highlight_set_entities") @attr.s(auto_attribs=True) class highlight_set_entities: @@ -1800,7 +1800,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QX], src_dict: Dict[str, Any]) -> QX: + def from_dict(cls: Type[NO], src_dict: Dict[str, Any]) -> NO: d = src_dict.copy() entities = cast(List[str], d.pop("entities", UNSET)) @@ -1834,7 +1834,7 @@ def __contains__(self, key: str) -> bool: -NO = TypeVar("NO", bound="new_annotation") +VX = TypeVar("VX", bound="new_annotation") @attr.s(auto_attribs=True) class new_annotation: @@ -1868,7 +1868,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NO], src_dict: Dict[str, Any]) -> NO: + def from_dict(cls: Type[VX], src_dict: Dict[str, Any]) -> VX: d = src_dict.copy() _annotation_type = d.pop("annotation_type", UNSET) annotation_type: Union[Unset, AnnotationType] @@ -1918,7 +1918,7 @@ def __contains__(self, key: str) -> bool: -VX = TypeVar("VX", bound="update_annotation") +RG = TypeVar("RG", bound="update_annotation") @attr.s(auto_attribs=True) class update_annotation: @@ -1947,7 +1947,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VX], src_dict: Dict[str, Any]) -> VX: + def from_dict(cls: Type[RG], src_dict: Dict[str, Any]) -> RG: d = src_dict.copy() annotation_id = d.pop("annotation_id", UNSET) @@ -1989,7 +1989,7 @@ def __contains__(self, key: str) -> bool: -RG = TypeVar("RG", bound="object_visible") +IT = TypeVar("IT", bound="object_visible") @attr.s(auto_attribs=True) class object_visible: @@ -2017,7 +2017,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RG], src_dict: Dict[str, Any]) -> RG: + def from_dict(cls: Type[IT], src_dict: Dict[str, Any]) -> IT: d = src_dict.copy() hidden = d.pop("hidden", UNSET) @@ -2054,7 +2054,65 @@ def __contains__(self, key: str) -> bool: -IT = TypeVar("IT", bound="get_entity_type") +LD = TypeVar("LD", bound="object_bring_to_front") + +@attr.s(auto_attribs=True) +class object_bring_to_front: + """ Bring an object to the front of the scene """ # noqa: E501 + object_id: Union[Unset, str] = UNSET + type: str = "object_bring_to_front" + + additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict) + + def to_dict(self) -> Dict[str, Any]: + object_id = self.object_id + type = self.type + + field_dict: Dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update({}) + if object_id is not UNSET: + field_dict['object_id'] = object_id + field_dict['type'] = type + + return field_dict + + @classmethod + def from_dict(cls: Type[LD], src_dict: Dict[str, Any]) -> LD: + d = src_dict.copy() + object_id = d.pop("object_id", UNSET) + + type = d.pop("type", UNSET) + + + object_bring_to_front = cls( + object_id= object_id, + type= type, + ) + + object_bring_to_front.additional_properties = d + return object_bring_to_front + + @property + def additional_keys(self) -> List[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties + + + + +UA = TypeVar("UA", bound="get_entity_type") @attr.s(auto_attribs=True) class get_entity_type: @@ -2078,7 +2136,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[IT], src_dict: Dict[str, Any]) -> IT: + def from_dict(cls: Type[UA], src_dict: Dict[str, Any]) -> UA: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) @@ -2112,7 +2170,7 @@ def __contains__(self, key: str) -> bool: -LD = TypeVar("LD", bound="solid3d_get_all_edge_faces") +TN = TypeVar("TN", bound="solid3d_get_all_edge_faces") @attr.s(auto_attribs=True) class solid3d_get_all_edge_faces: @@ -2140,7 +2198,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LD], src_dict: Dict[str, Any]) -> LD: + def from_dict(cls: Type[TN], src_dict: Dict[str, Any]) -> TN: d = src_dict.copy() edge_id = d.pop("edge_id", UNSET) @@ -2177,7 +2235,7 @@ def __contains__(self, key: str) -> bool: -UA = TypeVar("UA", bound="solid3d_get_all_opposite_edges") +MZ = TypeVar("MZ", bound="solid3d_get_all_opposite_edges") @attr.s(auto_attribs=True) class solid3d_get_all_opposite_edges: @@ -2210,7 +2268,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UA], src_dict: Dict[str, Any]) -> UA: + def from_dict(cls: Type[MZ], src_dict: Dict[str, Any]) -> MZ: d = src_dict.copy() _along_vector = d.pop("along_vector", UNSET) along_vector: Union[Unset, Point3d] @@ -2255,7 +2313,7 @@ def __contains__(self, key: str) -> bool: -TN = TypeVar("TN", bound="solid3d_get_opposite_edge") +UG = TypeVar("UG", bound="solid3d_get_opposite_edge") @attr.s(auto_attribs=True) class solid3d_get_opposite_edge: @@ -2287,7 +2345,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TN], src_dict: Dict[str, Any]) -> TN: + def from_dict(cls: Type[UG], src_dict: Dict[str, Any]) -> UG: d = src_dict.copy() edge_id = d.pop("edge_id", UNSET) @@ -2327,7 +2385,7 @@ def __contains__(self, key: str) -> bool: -MZ = TypeVar("MZ", bound="solid3d_get_next_adjacent_edge") +CY = TypeVar("CY", bound="solid3d_get_next_adjacent_edge") @attr.s(auto_attribs=True) class solid3d_get_next_adjacent_edge: @@ -2359,7 +2417,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MZ], src_dict: Dict[str, Any]) -> MZ: + def from_dict(cls: Type[CY], src_dict: Dict[str, Any]) -> CY: d = src_dict.copy() edge_id = d.pop("edge_id", UNSET) @@ -2399,7 +2457,7 @@ def __contains__(self, key: str) -> bool: -UG = TypeVar("UG", bound="solid3d_get_prev_adjacent_edge") +NZ = TypeVar("NZ", bound="solid3d_get_prev_adjacent_edge") @attr.s(auto_attribs=True) class solid3d_get_prev_adjacent_edge: @@ -2431,7 +2489,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UG], src_dict: Dict[str, Any]) -> UG: + def from_dict(cls: Type[NZ], src_dict: Dict[str, Any]) -> NZ: d = src_dict.copy() edge_id = d.pop("edge_id", UNSET) @@ -2471,7 +2529,7 @@ def __contains__(self, key: str) -> bool: -CY = TypeVar("CY", bound="send_object") +LI = TypeVar("LI", bound="send_object") @attr.s(auto_attribs=True) class send_object: @@ -2499,7 +2557,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CY], src_dict: Dict[str, Any]) -> CY: + def from_dict(cls: Type[LI], src_dict: Dict[str, Any]) -> LI: d = src_dict.copy() front = d.pop("front", UNSET) @@ -2536,7 +2594,7 @@ def __contains__(self, key: str) -> bool: -NZ = TypeVar("NZ", bound="entity_set_opacity") +LO = TypeVar("LO", bound="entity_set_opacity") @attr.s(auto_attribs=True) class entity_set_opacity: @@ -2564,7 +2622,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NZ], src_dict: Dict[str, Any]) -> NZ: + def from_dict(cls: Type[LO], src_dict: Dict[str, Any]) -> LO: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) @@ -2601,7 +2659,7 @@ def __contains__(self, key: str) -> bool: -LI = TypeVar("LI", bound="entity_fade") +XJ = TypeVar("XJ", bound="entity_fade") @attr.s(auto_attribs=True) class entity_fade: @@ -2633,7 +2691,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LI], src_dict: Dict[str, Any]) -> LI: + def from_dict(cls: Type[XJ], src_dict: Dict[str, Any]) -> XJ: d = src_dict.copy() duration_seconds = d.pop("duration_seconds", UNSET) @@ -2673,12 +2731,13 @@ def __contains__(self, key: str) -> bool: -LO = TypeVar("LO", bound="make_plane") +OW = TypeVar("OW", bound="make_plane") @attr.s(auto_attribs=True) class make_plane: """ Make a plane. """ # noqa: E501 clobber: Union[Unset, bool] = False + hide: Union[Unset, bool] = False origin: Union[Unset, Point3d] = UNSET size: Union[Unset, float] = UNSET type: str = "make_plane" @@ -2689,6 +2748,7 @@ class make_plane: def to_dict(self) -> Dict[str, Any]: clobber = self.clobber + hide = self.hide if not isinstance(self.origin, Unset): origin = self.origin size = self.size @@ -2703,6 +2763,8 @@ def to_dict(self) -> Dict[str, Any]: field_dict.update({}) if clobber is not UNSET: field_dict['clobber'] = clobber + if hide is not UNSET: + field_dict['hide'] = hide if origin is not UNSET: field_dict['origin'] = origin if size is not UNSET: @@ -2716,10 +2778,12 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LO], src_dict: Dict[str, Any]) -> LO: + def from_dict(cls: Type[OW], src_dict: Dict[str, Any]) -> OW: d = src_dict.copy() clobber = d.pop("clobber", UNSET) + hide = d.pop("hide", UNSET) + _origin = d.pop("origin", UNSET) origin: Union[Unset, Point3d] if isinstance(_origin, Unset): @@ -2748,6 +2812,7 @@ def from_dict(cls: Type[LO], src_dict: Dict[str, Any]) -> LO: make_plane = cls( clobber= clobber, + hide= hide, origin= origin, size= size, type= type, @@ -2777,7 +2842,7 @@ def __contains__(self, key: str) -> bool: -XJ = TypeVar("XJ", bound="plane_set_color") +JQ = TypeVar("JQ", bound="plane_set_color") @attr.s(auto_attribs=True) class plane_set_color: @@ -2806,7 +2871,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[XJ], src_dict: Dict[str, Any]) -> XJ: + def from_dict(cls: Type[JQ], src_dict: Dict[str, Any]) -> JQ: d = src_dict.copy() _color = d.pop("color", UNSET) color: Union[Unset, Color] @@ -2848,7 +2913,7 @@ def __contains__(self, key: str) -> bool: -OW = TypeVar("OW", bound="set_tool") +PQ = TypeVar("PQ", bound="set_tool") @attr.s(auto_attribs=True) class set_tool: @@ -2873,7 +2938,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OW], src_dict: Dict[str, Any]) -> OW: + def from_dict(cls: Type[PQ], src_dict: Dict[str, Any]) -> PQ: d = src_dict.copy() _tool = d.pop("tool", UNSET) tool: Union[Unset, SceneToolType] @@ -2912,7 +2977,7 @@ def __contains__(self, key: str) -> bool: -JQ = TypeVar("JQ", bound="mouse_move") +IM = TypeVar("IM", bound="mouse_move") @attr.s(auto_attribs=True) class mouse_move: @@ -2941,7 +3006,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JQ], src_dict: Dict[str, Any]) -> JQ: + def from_dict(cls: Type[IM], src_dict: Dict[str, Any]) -> IM: d = src_dict.copy() sequence = d.pop("sequence", UNSET) @@ -2983,7 +3048,7 @@ def __contains__(self, key: str) -> bool: -PQ = TypeVar("PQ", bound="mouse_click") +OU = TypeVar("OU", bound="mouse_click") @attr.s(auto_attribs=True) class mouse_click: @@ -3008,7 +3073,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PQ], src_dict: Dict[str, Any]) -> PQ: + def from_dict(cls: Type[OU], src_dict: Dict[str, Any]) -> OU: d = src_dict.copy() type = d.pop("type", UNSET) @@ -3047,12 +3112,13 @@ def __contains__(self, key: str) -> bool: -IM = TypeVar("IM", bound="sketch_mode_enable") +KL = TypeVar("KL", bound="sketch_mode_enable") @attr.s(auto_attribs=True) class sketch_mode_enable: """ Enable sketch mode on the given plane. """ # noqa: E501 animated: Union[Unset, bool] = False + disable_camera_with_plane: Union[Unset, Point3d] = UNSET ortho: Union[Unset, bool] = False plane_id: Union[Unset, str] = UNSET type: str = "sketch_mode_enable" @@ -3061,6 +3127,8 @@ class sketch_mode_enable: def to_dict(self) -> Dict[str, Any]: animated = self.animated + if not isinstance(self.disable_camera_with_plane, Unset): + disable_camera_with_plane = self.disable_camera_with_plane ortho = self.ortho plane_id = self.plane_id type = self.type @@ -3070,6 +3138,8 @@ def to_dict(self) -> Dict[str, Any]: field_dict.update({}) if animated is not UNSET: field_dict['animated'] = animated + if disable_camera_with_plane is not UNSET: + field_dict['disable_camera_with_plane'] = disable_camera_with_plane if ortho is not UNSET: field_dict['ortho'] = ortho if plane_id is not UNSET: @@ -3079,10 +3149,17 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[IM], src_dict: Dict[str, Any]) -> IM: + def from_dict(cls: Type[KL], src_dict: Dict[str, Any]) -> KL: d = src_dict.copy() animated = d.pop("animated", UNSET) + _disable_camera_with_plane = d.pop("disable_camera_with_plane", UNSET) + disable_camera_with_plane: Union[Unset, Point3d] + if isinstance(_disable_camera_with_plane, Unset): + disable_camera_with_plane = UNSET + else: + disable_camera_with_plane = _disable_camera_with_plane # type: ignore[arg-type] + ortho = d.pop("ortho", UNSET) plane_id = d.pop("plane_id", UNSET) @@ -3092,6 +3169,7 @@ def from_dict(cls: Type[IM], src_dict: Dict[str, Any]) -> IM: sketch_mode_enable = cls( animated= animated, + disable_camera_with_plane= disable_camera_with_plane, ortho= ortho, plane_id= plane_id, type= type, @@ -3119,7 +3197,7 @@ def __contains__(self, key: str) -> bool: -OU = TypeVar("OU", bound="sketch_mode_disable") +XI = TypeVar("XI", bound="sketch_mode_disable") @attr.s(auto_attribs=True) class sketch_mode_disable: @@ -3139,7 +3217,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OU], src_dict: Dict[str, Any]) -> OU: + def from_dict(cls: Type[XI], src_dict: Dict[str, Any]) -> XI: d = src_dict.copy() type = d.pop("type", UNSET) @@ -3170,7 +3248,7 @@ def __contains__(self, key: str) -> bool: -KL = TypeVar("KL", bound="curve_get_type") +PO = TypeVar("PO", bound="curve_get_type") @attr.s(auto_attribs=True) class curve_get_type: @@ -3194,7 +3272,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[KL], src_dict: Dict[str, Any]) -> KL: + def from_dict(cls: Type[PO], src_dict: Dict[str, Any]) -> PO: d = src_dict.copy() curve_id = d.pop("curve_id", UNSET) @@ -3228,7 +3306,7 @@ def __contains__(self, key: str) -> bool: -XI = TypeVar("XI", bound="curve_get_control_points") +PS = TypeVar("PS", bound="curve_get_control_points") @attr.s(auto_attribs=True) class curve_get_control_points: @@ -3252,7 +3330,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[XI], src_dict: Dict[str, Any]) -> XI: + def from_dict(cls: Type[PS], src_dict: Dict[str, Any]) -> PS: d = src_dict.copy() curve_id = d.pop("curve_id", UNSET) @@ -3286,7 +3364,7 @@ def __contains__(self, key: str) -> bool: -PO = TypeVar("PO", bound="take_snapshot") +WR = TypeVar("WR", bound="take_snapshot") @attr.s(auto_attribs=True) class take_snapshot: @@ -3311,7 +3389,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PO], src_dict: Dict[str, Any]) -> PO: + def from_dict(cls: Type[WR], src_dict: Dict[str, Any]) -> WR: d = src_dict.copy() _format = d.pop("format", UNSET) format: Union[Unset, ImageFormat] @@ -3350,7 +3428,7 @@ def __contains__(self, key: str) -> bool: -PS = TypeVar("PS", bound="make_axes_gizmo") +XL = TypeVar("XL", bound="make_axes_gizmo") @attr.s(auto_attribs=True) class make_axes_gizmo: @@ -3378,7 +3456,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PS], src_dict: Dict[str, Any]) -> PS: + def from_dict(cls: Type[XL], src_dict: Dict[str, Any]) -> XL: d = src_dict.copy() clobber = d.pop("clobber", UNSET) @@ -3415,7 +3493,7 @@ def __contains__(self, key: str) -> bool: -WR = TypeVar("WR", bound="path_get_info") +ZX = TypeVar("ZX", bound="path_get_info") @attr.s(auto_attribs=True) class path_get_info: @@ -3439,7 +3517,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WR], src_dict: Dict[str, Any]) -> WR: + def from_dict(cls: Type[ZX], src_dict: Dict[str, Any]) -> ZX: d = src_dict.copy() path_id = d.pop("path_id", UNSET) @@ -3473,7 +3551,7 @@ def __contains__(self, key: str) -> bool: -XL = TypeVar("XL", bound="path_get_curve_uuids_for_vertices") +FT = TypeVar("FT", bound="path_get_curve_uuids_for_vertices") @attr.s(auto_attribs=True) class path_get_curve_uuids_for_vertices: @@ -3503,7 +3581,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[XL], src_dict: Dict[str, Any]) -> XL: + def from_dict(cls: Type[FT], src_dict: Dict[str, Any]) -> FT: d = src_dict.copy() path_id = d.pop("path_id", UNSET) @@ -3540,7 +3618,7 @@ def __contains__(self, key: str) -> bool: -ZX = TypeVar("ZX", bound="handle_mouse_drag_start") +NX = TypeVar("NX", bound="handle_mouse_drag_start") @attr.s(auto_attribs=True) class handle_mouse_drag_start: @@ -3565,7 +3643,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZX], src_dict: Dict[str, Any]) -> ZX: + def from_dict(cls: Type[NX], src_dict: Dict[str, Any]) -> NX: d = src_dict.copy() type = d.pop("type", UNSET) @@ -3604,7 +3682,7 @@ def __contains__(self, key: str) -> bool: -FT = TypeVar("FT", bound="handle_mouse_drag_move") +SC = TypeVar("SC", bound="handle_mouse_drag_move") @attr.s(auto_attribs=True) class handle_mouse_drag_move: @@ -3633,7 +3711,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FT], src_dict: Dict[str, Any]) -> FT: + def from_dict(cls: Type[SC], src_dict: Dict[str, Any]) -> SC: d = src_dict.copy() sequence = d.pop("sequence", UNSET) @@ -3675,7 +3753,7 @@ def __contains__(self, key: str) -> bool: -NX = TypeVar("NX", bound="handle_mouse_drag_end") +TX = TypeVar("TX", bound="handle_mouse_drag_end") @attr.s(auto_attribs=True) class handle_mouse_drag_end: @@ -3700,7 +3778,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NX], src_dict: Dict[str, Any]) -> NX: + def from_dict(cls: Type[TX], src_dict: Dict[str, Any]) -> TX: d = src_dict.copy() type = d.pop("type", UNSET) @@ -3739,7 +3817,7 @@ def __contains__(self, key: str) -> bool: -SC = TypeVar("SC", bound="remove_scene_objects") +JA = TypeVar("JA", bound="remove_scene_objects") @attr.s(auto_attribs=True) class remove_scene_objects: @@ -3765,7 +3843,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SC], src_dict: Dict[str, Any]) -> SC: + def from_dict(cls: Type[JA], src_dict: Dict[str, Any]) -> JA: d = src_dict.copy() object_ids = cast(List[str], d.pop("object_ids", UNSET)) @@ -3799,7 +3877,7 @@ def __contains__(self, key: str) -> bool: -TX = TypeVar("TX", bound="plane_intersect_and_project") +SK = TypeVar("SK", bound="plane_intersect_and_project") @attr.s(auto_attribs=True) class plane_intersect_and_project: @@ -3828,7 +3906,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TX], src_dict: Dict[str, Any]) -> TX: + def from_dict(cls: Type[SK], src_dict: Dict[str, Any]) -> SK: d = src_dict.copy() plane_id = d.pop("plane_id", UNSET) @@ -3870,7 +3948,7 @@ def __contains__(self, key: str) -> bool: -JA = TypeVar("JA", bound="curve_get_end_points") +UK = TypeVar("UK", bound="curve_get_end_points") @attr.s(auto_attribs=True) class curve_get_end_points: @@ -3894,7 +3972,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JA], src_dict: Dict[str, Any]) -> JA: + def from_dict(cls: Type[UK], src_dict: Dict[str, Any]) -> UK: d = src_dict.copy() curve_id = d.pop("curve_id", UNSET) @@ -3928,7 +4006,7 @@ def __contains__(self, key: str) -> bool: -SK = TypeVar("SK", bound="reconfigure_stream") +CX = TypeVar("CX", bound="reconfigure_stream") @attr.s(auto_attribs=True) class reconfigure_stream: @@ -3960,7 +4038,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SK], src_dict: Dict[str, Any]) -> SK: + def from_dict(cls: Type[CX], src_dict: Dict[str, Any]) -> CX: d = src_dict.copy() fps = d.pop("fps", UNSET) @@ -4000,7 +4078,7 @@ def __contains__(self, key: str) -> bool: -UK = TypeVar("UK", bound="import_files") +MT = TypeVar("MT", bound="import_files") @attr.s(auto_attribs=True) class import_files: @@ -4028,7 +4106,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UK], src_dict: Dict[str, Any]) -> UK: + def from_dict(cls: Type[MT], src_dict: Dict[str, Any]) -> MT: d = src_dict.copy() from ..models.import_file import ImportFile files = cast(List[ImportFile], d.pop("files", UNSET)) @@ -4063,7 +4141,7 @@ def __contains__(self, key: str) -> bool: -CX = TypeVar("CX", bound="mass") +LJ = TypeVar("LJ", bound="mass") @attr.s(auto_attribs=True) class mass: @@ -4108,7 +4186,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CX], src_dict: Dict[str, Any]) -> CX: + def from_dict(cls: Type[LJ], src_dict: Dict[str, Any]) -> LJ: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -4169,7 +4247,7 @@ def __contains__(self, key: str) -> bool: -MT = TypeVar("MT", bound="density") +TF = TypeVar("TF", bound="density") @attr.s(auto_attribs=True) class density: @@ -4214,7 +4292,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MT], src_dict: Dict[str, Any]) -> MT: + def from_dict(cls: Type[TF], src_dict: Dict[str, Any]) -> TF: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -4275,7 +4353,7 @@ def __contains__(self, key: str) -> bool: -LJ = TypeVar("LJ", bound="volume") +HF = TypeVar("HF", bound="volume") @attr.s(auto_attribs=True) class volume: @@ -4311,7 +4389,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LJ], src_dict: Dict[str, Any]) -> LJ: + def from_dict(cls: Type[HF], src_dict: Dict[str, Any]) -> HF: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -4361,7 +4439,7 @@ def __contains__(self, key: str) -> bool: -TF = TypeVar("TF", bound="center_of_mass") +JD = TypeVar("JD", bound="center_of_mass") @attr.s(auto_attribs=True) class center_of_mass: @@ -4397,7 +4475,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TF], src_dict: Dict[str, Any]) -> TF: + def from_dict(cls: Type[JD], src_dict: Dict[str, Any]) -> JD: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -4447,7 +4525,7 @@ def __contains__(self, key: str) -> bool: -HF = TypeVar("HF", bound="surface_area") +RZ = TypeVar("RZ", bound="surface_area") @attr.s(auto_attribs=True) class surface_area: @@ -4483,7 +4561,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[HF], src_dict: Dict[str, Any]) -> HF: + def from_dict(cls: Type[RZ], src_dict: Dict[str, Any]) -> RZ: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) @@ -4530,4 +4608,55 @@ def __delitem__(self, key: str) -> None: def __contains__(self, key: str) -> bool: return key in self.additional_properties -ModelingCmd = Union[start_path, move_path_pen, extend_path, extrude, close_path, camera_drag_start, camera_drag_move, camera_drag_end, default_camera_look_at, default_camera_zoom, default_camera_enable_sketch_mode, default_camera_disable_sketch_mode, export, entity_get_parent_id, entity_get_num_children, entity_get_child_uuid, entity_get_all_child_uuids, edit_mode_enter, edit_mode_exit, select_with_point, select_clear, select_add, select_remove, select_replace, select_get, highlight_set_entity, highlight_set_entities, new_annotation, update_annotation, object_visible, get_entity_type, solid3d_get_all_edge_faces, solid3d_get_all_opposite_edges, solid3d_get_opposite_edge, solid3d_get_next_adjacent_edge, solid3d_get_prev_adjacent_edge, send_object, entity_set_opacity, entity_fade, make_plane, plane_set_color, set_tool, mouse_move, mouse_click, sketch_mode_enable, sketch_mode_disable, curve_get_type, curve_get_control_points, take_snapshot, make_axes_gizmo, path_get_info, path_get_curve_uuids_for_vertices, handle_mouse_drag_start, handle_mouse_drag_move, handle_mouse_drag_end, remove_scene_objects, plane_intersect_and_project, curve_get_end_points, reconfigure_stream, import_files, mass, density, volume, center_of_mass, surface_area] + + + +BH = TypeVar("BH", bound="get_sketch_mode_plane") + +@attr.s(auto_attribs=True) +class get_sketch_mode_plane: + """ Get the plane of the sketch mode. This is useful for getting the normal of the plane after a user selects a plane. """ # noqa: E501 + type: str = "get_sketch_mode_plane" + + additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict) + + def to_dict(self) -> Dict[str, Any]: + type = self.type + + field_dict: Dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update({}) + field_dict['type'] = type + + return field_dict + + @classmethod + def from_dict(cls: Type[BH], src_dict: Dict[str, Any]) -> BH: + d = src_dict.copy() + type = d.pop("type", UNSET) + + + get_sketch_mode_plane = cls( + type= type, + ) + + get_sketch_mode_plane.additional_properties = d + return get_sketch_mode_plane + + @property + def additional_keys(self) -> List[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties + +ModelingCmd = Union[start_path, move_path_pen, extend_path, extrude, close_path, camera_drag_start, camera_drag_move, camera_drag_end, default_camera_look_at, default_camera_zoom, default_camera_enable_sketch_mode, default_camera_disable_sketch_mode, export, entity_get_parent_id, entity_get_num_children, entity_get_child_uuid, entity_get_all_child_uuids, edit_mode_enter, edit_mode_exit, select_with_point, select_clear, select_add, select_remove, select_replace, select_get, highlight_set_entity, highlight_set_entities, new_annotation, update_annotation, object_visible, object_bring_to_front, get_entity_type, solid3d_get_all_edge_faces, solid3d_get_all_opposite_edges, solid3d_get_opposite_edge, solid3d_get_next_adjacent_edge, solid3d_get_prev_adjacent_edge, send_object, entity_set_opacity, entity_fade, make_plane, plane_set_color, set_tool, mouse_move, mouse_click, sketch_mode_enable, sketch_mode_disable, curve_get_type, curve_get_control_points, take_snapshot, make_axes_gizmo, path_get_info, path_get_curve_uuids_for_vertices, handle_mouse_drag_start, handle_mouse_drag_move, handle_mouse_drag_end, remove_scene_objects, plane_intersect_and_project, curve_get_end_points, reconfigure_stream, import_files, mass, density, volume, center_of_mass, surface_area, get_sketch_mode_plane] diff --git a/kittycad/models/mouse_click.py b/kittycad/models/mouse_click.py index e54909e32..380f55b27 100644 --- a/kittycad/models/mouse_click.py +++ b/kittycad/models/mouse_click.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -JD = TypeVar("JD", bound="MouseClick") +SX = TypeVar("SX", bound="MouseClick") @attr.s(auto_attribs=True) class MouseClick: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JD], src_dict: Dict[str, Any]) -> JD: + def from_dict(cls: Type[SX], src_dict: Dict[str, Any]) -> SX: d = src_dict.copy() entities_modified = cast(List[str], d.pop("entities_modified", UNSET)) diff --git a/kittycad/models/new_address.py b/kittycad/models/new_address.py index c88d47510..e0e9ba534 100644 --- a/kittycad/models/new_address.py +++ b/kittycad/models/new_address.py @@ -5,7 +5,7 @@ from ..models.country_code import CountryCode from ..types import UNSET, Unset -RZ = TypeVar("RZ", bound="NewAddress") +CN = TypeVar("CN", bound="NewAddress") @attr.s(auto_attribs=True) class NewAddress: @@ -51,7 +51,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RZ], src_dict: Dict[str, Any]) -> RZ: + def from_dict(cls: Type[CN], src_dict: Dict[str, Any]) -> CN: d = src_dict.copy() city = d.pop("city", UNSET) diff --git a/kittycad/models/o_auth2_client_info.py b/kittycad/models/o_auth2_client_info.py index 2d69f24c2..b9a7a06ae 100644 --- a/kittycad/models/o_auth2_client_info.py +++ b/kittycad/models/o_auth2_client_info.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -BH = TypeVar("BH", bound="OAuth2ClientInfo") +GS = TypeVar("GS", bound="OAuth2ClientInfo") @attr.s(auto_attribs=True) class OAuth2ClientInfo: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BH], src_dict: Dict[str, Any]) -> BH: + def from_dict(cls: Type[GS], src_dict: Dict[str, Any]) -> GS: d = src_dict.copy() csrf_token = d.pop("csrf_token", UNSET) diff --git a/kittycad/models/ok_modeling_cmd_response.py b/kittycad/models/ok_modeling_cmd_response.py index 75ef4af51..0eba65d6b 100644 --- a/kittycad/models/ok_modeling_cmd_response.py +++ b/kittycad/models/ok_modeling_cmd_response.py @@ -13,6 +13,7 @@ from ..models.entity_get_parent_id import EntityGetParentId from ..models.export import Export from ..models.get_entity_type import GetEntityType +from ..models.get_sketch_mode_plane import GetSketchModePlane from ..models.highlight_set_entity import HighlightSetEntity from ..models.import_files import ImportFiles from ..models.mass import Mass @@ -32,7 +33,7 @@ from ..models.volume import Volume from ..types import UNSET, Unset -SX = TypeVar("SX", bound="empty") +SO = TypeVar("SO", bound="empty") @attr.s(auto_attribs=True) class empty: @@ -52,7 +53,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SX], src_dict: Dict[str, Any]) -> SX: + def from_dict(cls: Type[SO], src_dict: Dict[str, Any]) -> SO: d = src_dict.copy() type = d.pop("type", UNSET) @@ -83,7 +84,7 @@ def __contains__(self, key: str) -> bool: -CN = TypeVar("CN", bound="export") +ZS = TypeVar("ZS", bound="export") @attr.s(auto_attribs=True) class export: @@ -108,7 +109,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CN], src_dict: Dict[str, Any]) -> CN: + def from_dict(cls: Type[ZS], src_dict: Dict[str, Any]) -> ZS: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Export] @@ -147,7 +148,7 @@ def __contains__(self, key: str) -> bool: -GS = TypeVar("GS", bound="select_with_point") +AM = TypeVar("AM", bound="select_with_point") @attr.s(auto_attribs=True) class select_with_point: @@ -172,7 +173,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GS], src_dict: Dict[str, Any]) -> GS: + def from_dict(cls: Type[AM], src_dict: Dict[str, Any]) -> AM: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, SelectWithPoint] @@ -211,7 +212,7 @@ def __contains__(self, key: str) -> bool: -SO = TypeVar("SO", bound="highlight_set_entity") +GK = TypeVar("GK", bound="highlight_set_entity") @attr.s(auto_attribs=True) class highlight_set_entity: @@ -236,7 +237,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SO], src_dict: Dict[str, Any]) -> SO: + def from_dict(cls: Type[GK], src_dict: Dict[str, Any]) -> GK: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, HighlightSetEntity] @@ -275,7 +276,7 @@ def __contains__(self, key: str) -> bool: -ZS = TypeVar("ZS", bound="entity_get_child_uuid") +SG = TypeVar("SG", bound="entity_get_child_uuid") @attr.s(auto_attribs=True) class entity_get_child_uuid: @@ -300,7 +301,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZS], src_dict: Dict[str, Any]) -> ZS: + def from_dict(cls: Type[SG], src_dict: Dict[str, Any]) -> SG: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, EntityGetChildUuid] @@ -339,7 +340,7 @@ def __contains__(self, key: str) -> bool: -AM = TypeVar("AM", bound="entity_get_num_children") +QZ = TypeVar("QZ", bound="entity_get_num_children") @attr.s(auto_attribs=True) class entity_get_num_children: @@ -364,7 +365,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AM], src_dict: Dict[str, Any]) -> AM: + def from_dict(cls: Type[QZ], src_dict: Dict[str, Any]) -> QZ: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, EntityGetNumChildren] @@ -403,7 +404,7 @@ def __contains__(self, key: str) -> bool: -GK = TypeVar("GK", bound="entity_get_parent_id") +SY = TypeVar("SY", bound="entity_get_parent_id") @attr.s(auto_attribs=True) class entity_get_parent_id: @@ -428,7 +429,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GK], src_dict: Dict[str, Any]) -> GK: + def from_dict(cls: Type[SY], src_dict: Dict[str, Any]) -> SY: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, EntityGetParentId] @@ -467,7 +468,7 @@ def __contains__(self, key: str) -> bool: -SG = TypeVar("SG", bound="entity_get_all_child_uuids") +YK = TypeVar("YK", bound="entity_get_all_child_uuids") @attr.s(auto_attribs=True) class entity_get_all_child_uuids: @@ -492,7 +493,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SG], src_dict: Dict[str, Any]) -> SG: + def from_dict(cls: Type[YK], src_dict: Dict[str, Any]) -> YK: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, EntityGetAllChildUuids] @@ -531,7 +532,7 @@ def __contains__(self, key: str) -> bool: -QZ = TypeVar("QZ", bound="select_get") +WS = TypeVar("WS", bound="select_get") @attr.s(auto_attribs=True) class select_get: @@ -556,7 +557,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QZ], src_dict: Dict[str, Any]) -> QZ: + def from_dict(cls: Type[WS], src_dict: Dict[str, Any]) -> WS: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, SelectGet] @@ -595,7 +596,7 @@ def __contains__(self, key: str) -> bool: -SY = TypeVar("SY", bound="get_entity_type") +SL = TypeVar("SL", bound="get_entity_type") @attr.s(auto_attribs=True) class get_entity_type: @@ -620,7 +621,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SY], src_dict: Dict[str, Any]) -> SY: + def from_dict(cls: Type[SL], src_dict: Dict[str, Any]) -> SL: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, GetEntityType] @@ -659,7 +660,7 @@ def __contains__(self, key: str) -> bool: -YK = TypeVar("YK", bound="solid3d_get_all_edge_faces") +MK = TypeVar("MK", bound="solid3d_get_all_edge_faces") @attr.s(auto_attribs=True) class solid3d_get_all_edge_faces: @@ -684,7 +685,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[YK], src_dict: Dict[str, Any]) -> YK: + def from_dict(cls: Type[MK], src_dict: Dict[str, Any]) -> MK: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Solid3dGetAllEdgeFaces] @@ -723,7 +724,7 @@ def __contains__(self, key: str) -> bool: -WS = TypeVar("WS", bound="solid3d_get_all_opposite_edges") +TU = TypeVar("TU", bound="solid3d_get_all_opposite_edges") @attr.s(auto_attribs=True) class solid3d_get_all_opposite_edges: @@ -748,7 +749,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WS], src_dict: Dict[str, Any]) -> WS: + def from_dict(cls: Type[TU], src_dict: Dict[str, Any]) -> TU: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Solid3dGetAllOppositeEdges] @@ -787,7 +788,7 @@ def __contains__(self, key: str) -> bool: -SL = TypeVar("SL", bound="solid3d_get_opposite_edge") +FY = TypeVar("FY", bound="solid3d_get_opposite_edge") @attr.s(auto_attribs=True) class solid3d_get_opposite_edge: @@ -812,7 +813,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SL], src_dict: Dict[str, Any]) -> SL: + def from_dict(cls: Type[FY], src_dict: Dict[str, Any]) -> FY: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Solid3dGetOppositeEdge] @@ -851,7 +852,7 @@ def __contains__(self, key: str) -> bool: -MK = TypeVar("MK", bound="solid3d_get_prev_adjacent_edge") +FD = TypeVar("FD", bound="solid3d_get_prev_adjacent_edge") @attr.s(auto_attribs=True) class solid3d_get_prev_adjacent_edge: @@ -876,7 +877,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MK], src_dict: Dict[str, Any]) -> MK: + def from_dict(cls: Type[FD], src_dict: Dict[str, Any]) -> FD: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Solid3dGetPrevAdjacentEdge] @@ -915,7 +916,7 @@ def __contains__(self, key: str) -> bool: -TU = TypeVar("TU", bound="solid3d_get_next_adjacent_edge") +TZ = TypeVar("TZ", bound="solid3d_get_next_adjacent_edge") @attr.s(auto_attribs=True) class solid3d_get_next_adjacent_edge: @@ -940,7 +941,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TU], src_dict: Dict[str, Any]) -> TU: + def from_dict(cls: Type[TZ], src_dict: Dict[str, Any]) -> TZ: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Solid3dGetNextAdjacentEdge] @@ -979,7 +980,7 @@ def __contains__(self, key: str) -> bool: -FY = TypeVar("FY", bound="mouse_click") +AX = TypeVar("AX", bound="mouse_click") @attr.s(auto_attribs=True) class mouse_click: @@ -1004,7 +1005,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FY], src_dict: Dict[str, Any]) -> FY: + def from_dict(cls: Type[AX], src_dict: Dict[str, Any]) -> AX: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, MouseClick] @@ -1043,7 +1044,7 @@ def __contains__(self, key: str) -> bool: -FD = TypeVar("FD", bound="curve_get_type") +RQ = TypeVar("RQ", bound="curve_get_type") @attr.s(auto_attribs=True) class curve_get_type: @@ -1068,7 +1069,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FD], src_dict: Dict[str, Any]) -> FD: + def from_dict(cls: Type[RQ], src_dict: Dict[str, Any]) -> RQ: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, CurveGetType] @@ -1107,7 +1108,7 @@ def __contains__(self, key: str) -> bool: -TZ = TypeVar("TZ", bound="curve_get_control_points") +ZL = TypeVar("ZL", bound="curve_get_control_points") @attr.s(auto_attribs=True) class curve_get_control_points: @@ -1132,7 +1133,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TZ], src_dict: Dict[str, Any]) -> TZ: + def from_dict(cls: Type[ZL], src_dict: Dict[str, Any]) -> ZL: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, CurveGetControlPoints] @@ -1171,7 +1172,7 @@ def __contains__(self, key: str) -> bool: -AX = TypeVar("AX", bound="take_snapshot") +CM = TypeVar("CM", bound="take_snapshot") @attr.s(auto_attribs=True) class take_snapshot: @@ -1196,7 +1197,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AX], src_dict: Dict[str, Any]) -> AX: + def from_dict(cls: Type[CM], src_dict: Dict[str, Any]) -> CM: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, TakeSnapshot] @@ -1235,7 +1236,7 @@ def __contains__(self, key: str) -> bool: -RQ = TypeVar("RQ", bound="path_get_info") +OS = TypeVar("OS", bound="path_get_info") @attr.s(auto_attribs=True) class path_get_info: @@ -1260,7 +1261,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RQ], src_dict: Dict[str, Any]) -> RQ: + def from_dict(cls: Type[OS], src_dict: Dict[str, Any]) -> OS: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, PathGetInfo] @@ -1299,7 +1300,7 @@ def __contains__(self, key: str) -> bool: -ZL = TypeVar("ZL", bound="path_get_curve_uuids_for_vertices") +WP = TypeVar("WP", bound="path_get_curve_uuids_for_vertices") @attr.s(auto_attribs=True) class path_get_curve_uuids_for_vertices: @@ -1324,7 +1325,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZL], src_dict: Dict[str, Any]) -> ZL: + def from_dict(cls: Type[WP], src_dict: Dict[str, Any]) -> WP: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, PathGetCurveUuidsForVertices] @@ -1363,7 +1364,7 @@ def __contains__(self, key: str) -> bool: -CM = TypeVar("CM", bound="plane_intersect_and_project") +XO = TypeVar("XO", bound="plane_intersect_and_project") @attr.s(auto_attribs=True) class plane_intersect_and_project: @@ -1388,7 +1389,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CM], src_dict: Dict[str, Any]) -> CM: + def from_dict(cls: Type[XO], src_dict: Dict[str, Any]) -> XO: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, PlaneIntersectAndProject] @@ -1427,7 +1428,7 @@ def __contains__(self, key: str) -> bool: -OS = TypeVar("OS", bound="curve_get_end_points") +LN = TypeVar("LN", bound="curve_get_end_points") @attr.s(auto_attribs=True) class curve_get_end_points: @@ -1452,7 +1453,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OS], src_dict: Dict[str, Any]) -> OS: + def from_dict(cls: Type[LN], src_dict: Dict[str, Any]) -> LN: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, CurveGetEndPoints] @@ -1491,7 +1492,7 @@ def __contains__(self, key: str) -> bool: -WP = TypeVar("WP", bound="import_files") +KR = TypeVar("KR", bound="import_files") @attr.s(auto_attribs=True) class import_files: @@ -1516,7 +1517,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WP], src_dict: Dict[str, Any]) -> WP: + def from_dict(cls: Type[KR], src_dict: Dict[str, Any]) -> KR: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, ImportFiles] @@ -1555,7 +1556,7 @@ def __contains__(self, key: str) -> bool: -XO = TypeVar("XO", bound="mass") +MG = TypeVar("MG", bound="mass") @attr.s(auto_attribs=True) class mass: @@ -1580,7 +1581,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[XO], src_dict: Dict[str, Any]) -> XO: + def from_dict(cls: Type[MG], src_dict: Dict[str, Any]) -> MG: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Mass] @@ -1619,7 +1620,7 @@ def __contains__(self, key: str) -> bool: -LN = TypeVar("LN", bound="volume") +UE = TypeVar("UE", bound="volume") @attr.s(auto_attribs=True) class volume: @@ -1644,7 +1645,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LN], src_dict: Dict[str, Any]) -> LN: + def from_dict(cls: Type[UE], src_dict: Dict[str, Any]) -> UE: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Volume] @@ -1683,7 +1684,7 @@ def __contains__(self, key: str) -> bool: -KR = TypeVar("KR", bound="density") +BF = TypeVar("BF", bound="density") @attr.s(auto_attribs=True) class density: @@ -1708,7 +1709,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[KR], src_dict: Dict[str, Any]) -> KR: + def from_dict(cls: Type[BF], src_dict: Dict[str, Any]) -> BF: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, Density] @@ -1747,7 +1748,7 @@ def __contains__(self, key: str) -> bool: -MG = TypeVar("MG", bound="surface_area") +UU = TypeVar("UU", bound="surface_area") @attr.s(auto_attribs=True) class surface_area: @@ -1772,7 +1773,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MG], src_dict: Dict[str, Any]) -> MG: + def from_dict(cls: Type[UU], src_dict: Dict[str, Any]) -> UU: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, SurfaceArea] @@ -1811,7 +1812,7 @@ def __contains__(self, key: str) -> bool: -UE = TypeVar("UE", bound="center_of_mass") +MB = TypeVar("MB", bound="center_of_mass") @attr.s(auto_attribs=True) class center_of_mass: @@ -1836,7 +1837,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UE], src_dict: Dict[str, Any]) -> UE: + def from_dict(cls: Type[MB], src_dict: Dict[str, Any]) -> MB: d = src_dict.copy() _data = d.pop("data", UNSET) data: Union[Unset, CenterOfMass] @@ -1872,4 +1873,68 @@ def __delitem__(self, key: str) -> None: def __contains__(self, key: str) -> bool: return key in self.additional_properties -OkModelingCmdResponse = Union[empty, export, select_with_point, highlight_set_entity, entity_get_child_uuid, entity_get_num_children, entity_get_parent_id, entity_get_all_child_uuids, select_get, get_entity_type, solid3d_get_all_edge_faces, solid3d_get_all_opposite_edges, solid3d_get_opposite_edge, solid3d_get_prev_adjacent_edge, solid3d_get_next_adjacent_edge, mouse_click, curve_get_type, curve_get_control_points, take_snapshot, path_get_info, path_get_curve_uuids_for_vertices, plane_intersect_and_project, curve_get_end_points, import_files, mass, volume, density, surface_area, center_of_mass] + + + +TB = TypeVar("TB", bound="get_sketch_mode_plane") + +@attr.s(auto_attribs=True) +class get_sketch_mode_plane: + """ The response from the `GetSketchModePlane` command. """ # noqa: E501 + data: Union[Unset, GetSketchModePlane] = UNSET + type: str = "get_sketch_mode_plane" + + additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict) + + def to_dict(self) -> Dict[str, Any]: + if not isinstance(self.data, Unset): + data = self.data + type = self.type + + field_dict: Dict[str, Any] = {} + field_dict.update(self.additional_properties) + field_dict.update({}) + if data is not UNSET: + field_dict['data'] = data + field_dict['type'] = type + + return field_dict + + @classmethod + def from_dict(cls: Type[TB], src_dict: Dict[str, Any]) -> TB: + d = src_dict.copy() + _data = d.pop("data", UNSET) + data: Union[Unset, GetSketchModePlane] + if isinstance(_data, Unset): + data = UNSET + else: + data = _data # type: ignore[arg-type] + + type = d.pop("type", UNSET) + + + get_sketch_mode_plane = cls( + data= data, + type= type, + ) + + get_sketch_mode_plane.additional_properties = d + return get_sketch_mode_plane + + @property + def additional_keys(self) -> List[str]: + return list(self.additional_properties.keys()) + + def __getitem__(self, key: str) -> Any: + return self.additional_properties[key] + + def __setitem__(self, key: str, value: Any) -> None: + self.additional_properties[key] = value + + def __delitem__(self, key: str) -> None: + del self.additional_properties[key] + + def __contains__(self, key: str) -> bool: + return key in self.additional_properties + +OkModelingCmdResponse = Union[empty, export, select_with_point, highlight_set_entity, entity_get_child_uuid, entity_get_num_children, entity_get_parent_id, entity_get_all_child_uuids, select_get, get_entity_type, solid3d_get_all_edge_faces, solid3d_get_all_opposite_edges, solid3d_get_opposite_edge, solid3d_get_prev_adjacent_edge, solid3d_get_next_adjacent_edge, mouse_click, curve_get_type, curve_get_control_points, take_snapshot, path_get_info, path_get_curve_uuids_for_vertices, plane_intersect_and_project, curve_get_end_points, import_files, mass, volume, density, surface_area, center_of_mass, get_sketch_mode_plane] diff --git a/kittycad/models/ok_web_socket_response_data.py b/kittycad/models/ok_web_socket_response_data.py index ced633279..ceb420f89 100644 --- a/kittycad/models/ok_web_socket_response_data.py +++ b/kittycad/models/ok_web_socket_response_data.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -BF = TypeVar("BF", bound="ice_server_info") +FJ = TypeVar("FJ", bound="ice_server_info") @attr.s(auto_attribs=True) class ice_server_info: @@ -28,7 +28,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BF], src_dict: Dict[str, Any]) -> BF: + def from_dict(cls: Type[FJ], src_dict: Dict[str, Any]) -> FJ: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) @@ -61,7 +61,7 @@ def __contains__(self, key: str) -> bool: -UU = TypeVar("UU", bound="trickle_ice") +HB = TypeVar("HB", bound="trickle_ice") @attr.s(auto_attribs=True) class trickle_ice: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UU], src_dict: Dict[str, Any]) -> UU: + def from_dict(cls: Type[HB], src_dict: Dict[str, Any]) -> HB: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) @@ -118,7 +118,7 @@ def __contains__(self, key: str) -> bool: -MB = TypeVar("MB", bound="sdp_answer") +SF = TypeVar("SF", bound="sdp_answer") @attr.s(auto_attribs=True) class sdp_answer: @@ -142,7 +142,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MB], src_dict: Dict[str, Any]) -> MB: + def from_dict(cls: Type[SF], src_dict: Dict[str, Any]) -> SF: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) @@ -175,7 +175,7 @@ def __contains__(self, key: str) -> bool: -TB = TypeVar("TB", bound="modeling") +DU = TypeVar("DU", bound="modeling") @attr.s(auto_attribs=True) class modeling: @@ -199,7 +199,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TB], src_dict: Dict[str, Any]) -> TB: + def from_dict(cls: Type[DU], src_dict: Dict[str, Any]) -> DU: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) @@ -232,7 +232,7 @@ def __contains__(self, key: str) -> bool: -FJ = TypeVar("FJ", bound="export") +BM = TypeVar("BM", bound="export") @attr.s(auto_attribs=True) class export: @@ -256,7 +256,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FJ], src_dict: Dict[str, Any]) -> FJ: + def from_dict(cls: Type[BM], src_dict: Dict[str, Any]) -> BM: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) @@ -289,7 +289,7 @@ def __contains__(self, key: str) -> bool: -HB = TypeVar("HB", bound="metrics_request") +TY = TypeVar("TY", bound="metrics_request") @attr.s(auto_attribs=True) class metrics_request: @@ -313,7 +313,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[HB], src_dict: Dict[str, Any]) -> HB: + def from_dict(cls: Type[TY], src_dict: Dict[str, Any]) -> TY: d = src_dict.copy() data = d.pop("data", UNSET) type = d.pop("type", UNSET) diff --git a/kittycad/models/onboarding.py b/kittycad/models/onboarding.py index 80e5785af..3bee88db8 100644 --- a/kittycad/models/onboarding.py +++ b/kittycad/models/onboarding.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -SF = TypeVar("SF", bound="Onboarding") +NC = TypeVar("NC", bound="Onboarding") @attr.s(auto_attribs=True) class Onboarding: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SF], src_dict: Dict[str, Any]) -> SF: + def from_dict(cls: Type[NC], src_dict: Dict[str, Any]) -> NC: d = src_dict.copy() first_call_from__their_machine_date = d.pop("first_call_from_their_machine_date", UNSET) diff --git a/kittycad/models/output_file.py b/kittycad/models/output_file.py index 504d56982..36c9ac31e 100644 --- a/kittycad/models/output_file.py +++ b/kittycad/models/output_file.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -DU = TypeVar("DU", bound="OutputFile") +GP = TypeVar("GP", bound="OutputFile") @attr.s(auto_attribs=True) class OutputFile: @@ -29,7 +29,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DU], src_dict: Dict[str, Any]) -> DU: + def from_dict(cls: Type[GP], src_dict: Dict[str, Any]) -> GP: d = src_dict.copy() contents = d.pop("contents", UNSET) diff --git a/kittycad/models/output_format.py b/kittycad/models/output_format.py index f29567673..afc5c6647 100644 --- a/kittycad/models/output_format.py +++ b/kittycad/models/output_format.py @@ -11,7 +11,7 @@ from ..models.unit_length import UnitLength from ..types import UNSET, Unset -BM = TypeVar("BM", bound="fbx") +FF = TypeVar("FF", bound="fbx") @attr.s(auto_attribs=True) class fbx: @@ -36,7 +36,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BM], src_dict: Dict[str, Any]) -> BM: + def from_dict(cls: Type[FF], src_dict: Dict[str, Any]) -> FF: d = src_dict.copy() _storage = d.pop("storage", UNSET) storage: Union[Unset, FbxStorage] @@ -75,7 +75,7 @@ def __contains__(self, key: str) -> bool: -TY = TypeVar("TY", bound="gltf") +YO = TypeVar("YO", bound="gltf") @attr.s(auto_attribs=True) class gltf: @@ -105,7 +105,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[TY], src_dict: Dict[str, Any]) -> TY: + def from_dict(cls: Type[YO], src_dict: Dict[str, Any]) -> YO: d = src_dict.copy() _presentation = d.pop("presentation", UNSET) presentation: Union[Unset, GltfPresentation] @@ -152,7 +152,7 @@ def __contains__(self, key: str) -> bool: -NC = TypeVar("NC", bound="obj") +FS = TypeVar("FS", bound="obj") @attr.s(auto_attribs=True) class obj: @@ -182,7 +182,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[NC], src_dict: Dict[str, Any]) -> NC: + def from_dict(cls: Type[FS], src_dict: Dict[str, Any]) -> FS: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] @@ -229,7 +229,7 @@ def __contains__(self, key: str) -> bool: -GP = TypeVar("GP", bound="ply") +WN = TypeVar("WN", bound="ply") @attr.s(auto_attribs=True) class ply: @@ -259,7 +259,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GP], src_dict: Dict[str, Any]) -> GP: + def from_dict(cls: Type[WN], src_dict: Dict[str, Any]) -> WN: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] @@ -306,7 +306,7 @@ def __contains__(self, key: str) -> bool: -FF = TypeVar("FF", bound="step") +EQ = TypeVar("EQ", bound="step") @attr.s(auto_attribs=True) class step: @@ -331,7 +331,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FF], src_dict: Dict[str, Any]) -> FF: + def from_dict(cls: Type[EQ], src_dict: Dict[str, Any]) -> EQ: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] @@ -370,7 +370,7 @@ def __contains__(self, key: str) -> bool: -YO = TypeVar("YO", bound="stl") +UW = TypeVar("UW", bound="stl") @attr.s(auto_attribs=True) class stl: @@ -405,7 +405,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[YO], src_dict: Dict[str, Any]) -> YO: + def from_dict(cls: Type[UW], src_dict: Dict[str, Any]) -> UW: d = src_dict.copy() _coords = d.pop("coords", UNSET) coords: Union[Unset, System] diff --git a/kittycad/models/path_get_curve_uuids_for_vertices.py b/kittycad/models/path_get_curve_uuids_for_vertices.py index 45cb6ca95..06a4ee434 100644 --- a/kittycad/models/path_get_curve_uuids_for_vertices.py +++ b/kittycad/models/path_get_curve_uuids_for_vertices.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -FS = TypeVar("FS", bound="PathGetCurveUuidsForVertices") +MD = TypeVar("MD", bound="PathGetCurveUuidsForVertices") @attr.s(auto_attribs=True) class PathGetCurveUuidsForVertices: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FS], src_dict: Dict[str, Any]) -> FS: + def from_dict(cls: Type[MD], src_dict: Dict[str, Any]) -> MD: d = src_dict.copy() curve_ids = cast(List[str], d.pop("curve_ids", UNSET)) diff --git a/kittycad/models/path_get_info.py b/kittycad/models/path_get_info.py index 19b8879b5..c696a89c0 100644 --- a/kittycad/models/path_get_info.py +++ b/kittycad/models/path_get_info.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -WN = TypeVar("WN", bound="PathGetInfo") +HD = TypeVar("HD", bound="PathGetInfo") @attr.s(auto_attribs=True) class PathGetInfo: @@ -29,7 +29,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WN], src_dict: Dict[str, Any]) -> WN: + def from_dict(cls: Type[HD], src_dict: Dict[str, Any]) -> HD: d = src_dict.copy() from ..models.path_segment_info import PathSegmentInfo segments = cast(List[PathSegmentInfo], d.pop("segments", UNSET)) diff --git a/kittycad/models/path_segment.py b/kittycad/models/path_segment.py index da730d0a0..c03a32102 100644 --- a/kittycad/models/path_segment.py +++ b/kittycad/models/path_segment.py @@ -7,7 +7,7 @@ from ..models.point3d import Point3d from ..types import UNSET, Unset -EQ = TypeVar("EQ", bound="line") +UJ = TypeVar("UJ", bound="line") @attr.s(auto_attribs=True) class line: @@ -36,7 +36,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[EQ], src_dict: Dict[str, Any]) -> EQ: + def from_dict(cls: Type[UJ], src_dict: Dict[str, Any]) -> UJ: d = src_dict.copy() _end = d.pop("end", UNSET) end: Union[Unset, Point3d] @@ -78,7 +78,7 @@ def __contains__(self, key: str) -> bool: -UW = TypeVar("UW", bound="arc") +RU = TypeVar("RU", bound="arc") @attr.s(auto_attribs=True) class arc: @@ -119,7 +119,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UW], src_dict: Dict[str, Any]) -> UW: + def from_dict(cls: Type[RU], src_dict: Dict[str, Any]) -> RU: d = src_dict.copy() angle_end = d.pop("angle_end", UNSET) @@ -170,7 +170,7 @@ def __contains__(self, key: str) -> bool: -MD = TypeVar("MD", bound="bezier") +DL = TypeVar("DL", bound="bezier") @attr.s(auto_attribs=True) class bezier: @@ -209,7 +209,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MD], src_dict: Dict[str, Any]) -> MD: + def from_dict(cls: Type[DL], src_dict: Dict[str, Any]) -> DL: d = src_dict.copy() _control1 = d.pop("control1", UNSET) control1: Union[Unset, Point3d] @@ -267,7 +267,7 @@ def __contains__(self, key: str) -> bool: -HD = TypeVar("HD", bound="tangential_arc") +QT = TypeVar("QT", bound="tangential_arc") @attr.s(auto_attribs=True) class tangential_arc: @@ -296,7 +296,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[HD], src_dict: Dict[str, Any]) -> HD: + def from_dict(cls: Type[QT], src_dict: Dict[str, Any]) -> QT: d = src_dict.copy() _offset = d.pop("offset", UNSET) offset: Union[Unset, Angle] @@ -338,7 +338,7 @@ def __contains__(self, key: str) -> bool: -UJ = TypeVar("UJ", bound="tangential_arc_to") +PT = TypeVar("PT", bound="tangential_arc_to") @attr.s(auto_attribs=True) class tangential_arc_to: @@ -368,7 +368,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UJ], src_dict: Dict[str, Any]) -> UJ: + def from_dict(cls: Type[PT], src_dict: Dict[str, Any]) -> PT: d = src_dict.copy() _angle_snap_increment = d.pop("angle_snap_increment", UNSET) angle_snap_increment: Union[Unset, Angle] diff --git a/kittycad/models/path_segment_info.py b/kittycad/models/path_segment_info.py index f7e108878..a7617f9e4 100644 --- a/kittycad/models/path_segment_info.py +++ b/kittycad/models/path_segment_info.py @@ -6,7 +6,7 @@ from ..models.path_command import PathCommand from ..types import UNSET, Unset -RU = TypeVar("RU", bound="PathSegmentInfo") +HR = TypeVar("HR", bound="PathSegmentInfo") @attr.s(auto_attribs=True) class PathSegmentInfo: @@ -37,7 +37,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RU], src_dict: Dict[str, Any]) -> RU: + def from_dict(cls: Type[HR], src_dict: Dict[str, Any]) -> HR: d = src_dict.copy() _command = d.pop("command", UNSET) command: Union[Unset, PathCommand] diff --git a/kittycad/models/payment_intent.py b/kittycad/models/payment_intent.py index 617912a57..ce11a02ab 100644 --- a/kittycad/models/payment_intent.py +++ b/kittycad/models/payment_intent.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -DL = TypeVar("DL", bound="PaymentIntent") +VF = TypeVar("VF", bound="PaymentIntent") @attr.s(auto_attribs=True) class PaymentIntent: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DL], src_dict: Dict[str, Any]) -> DL: + def from_dict(cls: Type[VF], src_dict: Dict[str, Any]) -> VF: d = src_dict.copy() client_secret = d.pop("client_secret", UNSET) diff --git a/kittycad/models/payment_method.py b/kittycad/models/payment_method.py index 971ec65e7..9b0b779f0 100644 --- a/kittycad/models/payment_method.py +++ b/kittycad/models/payment_method.py @@ -9,7 +9,7 @@ from ..models.payment_method_type import PaymentMethodType from ..types import UNSET, Unset -QT = TypeVar("QT", bound="PaymentMethod") +VM = TypeVar("VM", bound="PaymentMethod") @attr.s(auto_attribs=True) class PaymentMethod: @@ -56,7 +56,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QT], src_dict: Dict[str, Any]) -> QT: + def from_dict(cls: Type[VM], src_dict: Dict[str, Any]) -> VM: d = src_dict.copy() _billing_info = d.pop("billing_info", UNSET) billing_info: Union[Unset, BillingInfo] diff --git a/kittycad/models/payment_method_card_checks.py b/kittycad/models/payment_method_card_checks.py index fccf8bae1..141251ac4 100644 --- a/kittycad/models/payment_method_card_checks.py +++ b/kittycad/models/payment_method_card_checks.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -PT = TypeVar("PT", bound="PaymentMethodCardChecks") +WH = TypeVar("WH", bound="PaymentMethodCardChecks") @attr.s(auto_attribs=True) class PaymentMethodCardChecks: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PT], src_dict: Dict[str, Any]) -> PT: + def from_dict(cls: Type[WH], src_dict: Dict[str, Any]) -> WH: d = src_dict.copy() address_line1_check = d.pop("address_line1_check", UNSET) diff --git a/kittycad/models/plane_intersect_and_project.py b/kittycad/models/plane_intersect_and_project.py index 3874aa3f2..5d471cd00 100644 --- a/kittycad/models/plane_intersect_and_project.py +++ b/kittycad/models/plane_intersect_and_project.py @@ -5,7 +5,7 @@ from ..models.point2d import Point2d from ..types import UNSET, Unset -HR = TypeVar("HR", bound="PlaneIntersectAndProject") +DQ = TypeVar("DQ", bound="PlaneIntersectAndProject") @attr.s(auto_attribs=True) class PlaneIntersectAndProject: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[HR], src_dict: Dict[str, Any]) -> HR: + def from_dict(cls: Type[DQ], src_dict: Dict[str, Any]) -> DQ: d = src_dict.copy() _plane_coordinates = d.pop("plane_coordinates", UNSET) plane_coordinates: Union[Unset, Point2d] diff --git a/kittycad/models/point2d.py b/kittycad/models/point2d.py index 4a67d6eb6..64ddaa54b 100644 --- a/kittycad/models/point2d.py +++ b/kittycad/models/point2d.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -VF = TypeVar("VF", bound="Point2d") +UY = TypeVar("UY", bound="Point2d") @attr.s(auto_attribs=True) class Point2d: @@ -29,7 +29,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VF], src_dict: Dict[str, Any]) -> VF: + def from_dict(cls: Type[UY], src_dict: Dict[str, Any]) -> UY: d = src_dict.copy() x = d.pop("x", UNSET) diff --git a/kittycad/models/point3d.py b/kittycad/models/point3d.py index 22186534b..b815d91c7 100644 --- a/kittycad/models/point3d.py +++ b/kittycad/models/point3d.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -VM = TypeVar("VM", bound="Point3d") +PD = TypeVar("PD", bound="Point3d") @attr.s(auto_attribs=True) class Point3d: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VM], src_dict: Dict[str, Any]) -> VM: + def from_dict(cls: Type[PD], src_dict: Dict[str, Any]) -> PD: d = src_dict.copy() x = d.pop("x", UNSET) diff --git a/kittycad/models/point_e_metadata.py b/kittycad/models/point_e_metadata.py index 726dd06ba..3cfe5b36c 100644 --- a/kittycad/models/point_e_metadata.py +++ b/kittycad/models/point_e_metadata.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -WH = TypeVar("WH", bound="PointEMetadata") +SM = TypeVar("SM", bound="PointEMetadata") @attr.s(auto_attribs=True) class PointEMetadata: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WH], src_dict: Dict[str, Any]) -> WH: + def from_dict(cls: Type[SM], src_dict: Dict[str, Any]) -> SM: d = src_dict.copy() ok = d.pop("ok", UNSET) diff --git a/kittycad/models/pong.py b/kittycad/models/pong.py index e5cb5207b..29a5903e3 100644 --- a/kittycad/models/pong.py +++ b/kittycad/models/pong.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -DQ = TypeVar("DQ", bound="Pong") +JL = TypeVar("JL", bound="Pong") @attr.s(auto_attribs=True) class Pong: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DQ], src_dict: Dict[str, Any]) -> DQ: + def from_dict(cls: Type[JL], src_dict: Dict[str, Any]) -> JL: d = src_dict.copy() message = d.pop("message", UNSET) diff --git a/kittycad/models/raw_file.py b/kittycad/models/raw_file.py index 93685a3e3..41373cbb9 100644 --- a/kittycad/models/raw_file.py +++ b/kittycad/models/raw_file.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -UY = TypeVar("UY", bound="RawFile") +CG = TypeVar("CG", bound="RawFile") @attr.s(auto_attribs=True) class RawFile: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[UY], src_dict: Dict[str, Any]) -> UY: + def from_dict(cls: Type[CG], src_dict: Dict[str, Any]) -> CG: d = src_dict.copy() contents = cast(List[int], d.pop("contents", UNSET)) diff --git a/kittycad/models/rtc_ice_candidate_init.py b/kittycad/models/rtc_ice_candidate_init.py index 335d98822..759231497 100644 --- a/kittycad/models/rtc_ice_candidate_init.py +++ b/kittycad/models/rtc_ice_candidate_init.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -PD = TypeVar("PD", bound="RtcIceCandidateInit") +QA = TypeVar("QA", bound="RtcIceCandidateInit") @attr.s(auto_attribs=True) class RtcIceCandidateInit: @@ -37,7 +37,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PD], src_dict: Dict[str, Any]) -> PD: + def from_dict(cls: Type[QA], src_dict: Dict[str, Any]) -> QA: d = src_dict.copy() candidate = d.pop("candidate", UNSET) diff --git a/kittycad/models/rtc_session_description.py b/kittycad/models/rtc_session_description.py index 1661a0422..ceab38c9f 100644 --- a/kittycad/models/rtc_session_description.py +++ b/kittycad/models/rtc_session_description.py @@ -5,7 +5,7 @@ from ..models.rtc_sdp_type import RtcSdpType from ..types import UNSET, Unset -SM = TypeVar("SM", bound="RtcSessionDescription") +ZB = TypeVar("ZB", bound="RtcSessionDescription") @attr.s(auto_attribs=True) class RtcSessionDescription: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[SM], src_dict: Dict[str, Any]) -> SM: + def from_dict(cls: Type[ZB], src_dict: Dict[str, Any]) -> ZB: d = src_dict.copy() sdp = d.pop("sdp", UNSET) diff --git a/kittycad/models/select_get.py b/kittycad/models/select_get.py index 70c00e1b2..f3ca2c95f 100644 --- a/kittycad/models/select_get.py +++ b/kittycad/models/select_get.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -JL = TypeVar("JL", bound="SelectGet") +AU = TypeVar("AU", bound="SelectGet") @attr.s(auto_attribs=True) class SelectGet: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JL], src_dict: Dict[str, Any]) -> JL: + def from_dict(cls: Type[AU], src_dict: Dict[str, Any]) -> AU: d = src_dict.copy() entity_ids = cast(List[str], d.pop("entity_ids", UNSET)) diff --git a/kittycad/models/select_with_point.py b/kittycad/models/select_with_point.py index 7f4779a52..7ae8ea527 100644 --- a/kittycad/models/select_with_point.py +++ b/kittycad/models/select_with_point.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -CG = TypeVar("CG", bound="SelectWithPoint") +FX = TypeVar("FX", bound="SelectWithPoint") @attr.s(auto_attribs=True) class SelectWithPoint: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CG], src_dict: Dict[str, Any]) -> CG: + def from_dict(cls: Type[FX], src_dict: Dict[str, Any]) -> FX: d = src_dict.copy() entity_id = d.pop("entity_id", UNSET) diff --git a/kittycad/models/session.py b/kittycad/models/session.py index e52d3c33b..374d23310 100644 --- a/kittycad/models/session.py +++ b/kittycad/models/session.py @@ -7,7 +7,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -QA = TypeVar("QA", bound="Session") +BL = TypeVar("BL", bound="Session") @attr.s(auto_attribs=True) class Session: @@ -56,7 +56,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[QA], src_dict: Dict[str, Any]) -> QA: + def from_dict(cls: Type[BL], src_dict: Dict[str, Any]) -> BL: d = src_dict.copy() _created_at = d.pop("created_at", UNSET) created_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/solid3d_get_all_edge_faces.py b/kittycad/models/solid3d_get_all_edge_faces.py index 1b63b900f..806b5a3e5 100644 --- a/kittycad/models/solid3d_get_all_edge_faces.py +++ b/kittycad/models/solid3d_get_all_edge_faces.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -ZB = TypeVar("ZB", bound="Solid3dGetAllEdgeFaces") +KU = TypeVar("KU", bound="Solid3dGetAllEdgeFaces") @attr.s(auto_attribs=True) class Solid3dGetAllEdgeFaces: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[ZB], src_dict: Dict[str, Any]) -> ZB: + def from_dict(cls: Type[KU], src_dict: Dict[str, Any]) -> KU: d = src_dict.copy() faces = cast(List[str], d.pop("faces", UNSET)) diff --git a/kittycad/models/solid3d_get_all_opposite_edges.py b/kittycad/models/solid3d_get_all_opposite_edges.py index 8dc08ddc5..bd596e24b 100644 --- a/kittycad/models/solid3d_get_all_opposite_edges.py +++ b/kittycad/models/solid3d_get_all_opposite_edges.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -AU = TypeVar("AU", bound="Solid3dGetAllOppositeEdges") +PZ = TypeVar("PZ", bound="Solid3dGetAllOppositeEdges") @attr.s(auto_attribs=True) class Solid3dGetAllOppositeEdges: @@ -27,7 +27,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AU], src_dict: Dict[str, Any]) -> AU: + def from_dict(cls: Type[PZ], src_dict: Dict[str, Any]) -> PZ: d = src_dict.copy() edges = cast(List[str], d.pop("edges", UNSET)) diff --git a/kittycad/models/solid3d_get_next_adjacent_edge.py b/kittycad/models/solid3d_get_next_adjacent_edge.py index 582076fc7..fe64d8824 100644 --- a/kittycad/models/solid3d_get_next_adjacent_edge.py +++ b/kittycad/models/solid3d_get_next_adjacent_edge.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -FX = TypeVar("FX", bound="Solid3dGetNextAdjacentEdge") +FA = TypeVar("FA", bound="Solid3dGetNextAdjacentEdge") @attr.s(auto_attribs=True) class Solid3dGetNextAdjacentEdge: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FX], src_dict: Dict[str, Any]) -> FX: + def from_dict(cls: Type[FA], src_dict: Dict[str, Any]) -> FA: d = src_dict.copy() edge = d.pop("edge", UNSET) diff --git a/kittycad/models/solid3d_get_opposite_edge.py b/kittycad/models/solid3d_get_opposite_edge.py index 43b66d383..820a8b856 100644 --- a/kittycad/models/solid3d_get_opposite_edge.py +++ b/kittycad/models/solid3d_get_opposite_edge.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -BL = TypeVar("BL", bound="Solid3dGetOppositeEdge") +GE = TypeVar("GE", bound="Solid3dGetOppositeEdge") @attr.s(auto_attribs=True) class Solid3dGetOppositeEdge: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BL], src_dict: Dict[str, Any]) -> BL: + def from_dict(cls: Type[GE], src_dict: Dict[str, Any]) -> GE: d = src_dict.copy() edge = d.pop("edge", UNSET) diff --git a/kittycad/models/solid3d_get_prev_adjacent_edge.py b/kittycad/models/solid3d_get_prev_adjacent_edge.py index 408df10a0..8cdc97d7f 100644 --- a/kittycad/models/solid3d_get_prev_adjacent_edge.py +++ b/kittycad/models/solid3d_get_prev_adjacent_edge.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -KU = TypeVar("KU", bound="Solid3dGetPrevAdjacentEdge") +JG = TypeVar("JG", bound="Solid3dGetPrevAdjacentEdge") @attr.s(auto_attribs=True) class Solid3dGetPrevAdjacentEdge: @@ -25,7 +25,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[KU], src_dict: Dict[str, Any]) -> KU: + def from_dict(cls: Type[JG], src_dict: Dict[str, Any]) -> JG: d = src_dict.copy() edge = d.pop("edge", UNSET) diff --git a/kittycad/models/success_web_socket_response.py b/kittycad/models/success_web_socket_response.py index 610848a01..fdc8eaa97 100644 --- a/kittycad/models/success_web_socket_response.py +++ b/kittycad/models/success_web_socket_response.py @@ -5,7 +5,7 @@ from ..models.ok_web_socket_response_data import OkWebSocketResponseData from ..types import UNSET, Unset -PZ = TypeVar("PZ", bound="SuccessWebSocketResponse") +HH = TypeVar("HH", bound="SuccessWebSocketResponse") @attr.s(auto_attribs=True) class SuccessWebSocketResponse: @@ -35,7 +35,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[PZ], src_dict: Dict[str, Any]) -> PZ: + def from_dict(cls: Type[HH], src_dict: Dict[str, Any]) -> HH: d = src_dict.copy() request_id = d.pop("request_id", UNSET) diff --git a/kittycad/models/surface_area.py b/kittycad/models/surface_area.py index bd96185a3..5915362ab 100644 --- a/kittycad/models/surface_area.py +++ b/kittycad/models/surface_area.py @@ -5,7 +5,7 @@ from ..models.unit_area import UnitArea from ..types import UNSET, Unset -FA = TypeVar("FA", bound="SurfaceArea") +RY = TypeVar("RY", bound="SurfaceArea") @attr.s(auto_attribs=True) class SurfaceArea: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FA], src_dict: Dict[str, Any]) -> FA: + def from_dict(cls: Type[RY], src_dict: Dict[str, Any]) -> RY: d = src_dict.copy() _output_unit = d.pop("output_unit", UNSET) output_unit: Union[Unset, UnitArea] diff --git a/kittycad/models/system.py b/kittycad/models/system.py index 025cac86b..9d78454fa 100644 --- a/kittycad/models/system.py +++ b/kittycad/models/system.py @@ -5,7 +5,7 @@ from ..models.axis_direction_pair import AxisDirectionPair from ..types import UNSET, Unset -GE = TypeVar("GE", bound="System") +AE = TypeVar("AE", bound="System") @attr.s(auto_attribs=True) class System: @@ -38,7 +38,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[GE], src_dict: Dict[str, Any]) -> GE: + def from_dict(cls: Type[AE], src_dict: Dict[str, Any]) -> AE: d = src_dict.copy() _forward = d.pop("forward", UNSET) forward: Union[Unset, AxisDirectionPair] diff --git a/kittycad/models/take_snapshot.py b/kittycad/models/take_snapshot.py index 1272fbbf9..b4ac173a1 100644 --- a/kittycad/models/take_snapshot.py +++ b/kittycad/models/take_snapshot.py @@ -5,7 +5,7 @@ from ..models.base64data import Base64Data from ..types import UNSET, Unset -JG = TypeVar("JG", bound="TakeSnapshot") +AD = TypeVar("AD", bound="TakeSnapshot") @attr.s(auto_attribs=True) class TakeSnapshot: @@ -28,7 +28,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JG], src_dict: Dict[str, Any]) -> JG: + def from_dict(cls: Type[AD], src_dict: Dict[str, Any]) -> AD: d = src_dict.copy() _contents = d.pop("contents", UNSET) contents: Union[Unset, Base64Data] diff --git a/kittycad/models/unit_angle_conversion.py b/kittycad/models/unit_angle_conversion.py index e87e2eccc..bed6feb8e 100644 --- a/kittycad/models/unit_angle_conversion.py +++ b/kittycad/models/unit_angle_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -HH = TypeVar("HH", bound="UnitAngleConversion") +AB = TypeVar("AB", bound="UnitAngleConversion") @attr.s(auto_attribs=True) class UnitAngleConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[HH], src_dict: Dict[str, Any]) -> HH: + def from_dict(cls: Type[AB], src_dict: Dict[str, Any]) -> AB: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_area_conversion.py b/kittycad/models/unit_area_conversion.py index c04843152..96a83dcd9 100644 --- a/kittycad/models/unit_area_conversion.py +++ b/kittycad/models/unit_area_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -RY = TypeVar("RY", bound="UnitAreaConversion") +VY = TypeVar("VY", bound="UnitAreaConversion") @attr.s(auto_attribs=True) class UnitAreaConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RY], src_dict: Dict[str, Any]) -> RY: + def from_dict(cls: Type[VY], src_dict: Dict[str, Any]) -> VY: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_current_conversion.py b/kittycad/models/unit_current_conversion.py index 7bbee1cda..bc024d543 100644 --- a/kittycad/models/unit_current_conversion.py +++ b/kittycad/models/unit_current_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -AE = TypeVar("AE", bound="UnitCurrentConversion") +DW = TypeVar("DW", bound="UnitCurrentConversion") @attr.s(auto_attribs=True) class UnitCurrentConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AE], src_dict: Dict[str, Any]) -> AE: + def from_dict(cls: Type[DW], src_dict: Dict[str, Any]) -> DW: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_energy_conversion.py b/kittycad/models/unit_energy_conversion.py index 53f2869a5..bdffbe689 100644 --- a/kittycad/models/unit_energy_conversion.py +++ b/kittycad/models/unit_energy_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -AD = TypeVar("AD", bound="UnitEnergyConversion") +MC = TypeVar("MC", bound="UnitEnergyConversion") @attr.s(auto_attribs=True) class UnitEnergyConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AD], src_dict: Dict[str, Any]) -> AD: + def from_dict(cls: Type[MC], src_dict: Dict[str, Any]) -> MC: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_force_conversion.py b/kittycad/models/unit_force_conversion.py index 3a1f87bc3..cbc5294f4 100644 --- a/kittycad/models/unit_force_conversion.py +++ b/kittycad/models/unit_force_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -AB = TypeVar("AB", bound="UnitForceConversion") +AV = TypeVar("AV", bound="UnitForceConversion") @attr.s(auto_attribs=True) class UnitForceConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AB], src_dict: Dict[str, Any]) -> AB: + def from_dict(cls: Type[AV], src_dict: Dict[str, Any]) -> AV: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_frequency_conversion.py b/kittycad/models/unit_frequency_conversion.py index aa1972b03..3d04c61bc 100644 --- a/kittycad/models/unit_frequency_conversion.py +++ b/kittycad/models/unit_frequency_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -VY = TypeVar("VY", bound="UnitFrequencyConversion") +BR = TypeVar("BR", bound="UnitFrequencyConversion") @attr.s(auto_attribs=True) class UnitFrequencyConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[VY], src_dict: Dict[str, Any]) -> VY: + def from_dict(cls: Type[BR], src_dict: Dict[str, Any]) -> BR: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_length_conversion.py b/kittycad/models/unit_length_conversion.py index 85a9119c0..4146ce4f9 100644 --- a/kittycad/models/unit_length_conversion.py +++ b/kittycad/models/unit_length_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -DW = TypeVar("DW", bound="UnitLengthConversion") +WM = TypeVar("WM", bound="UnitLengthConversion") @attr.s(auto_attribs=True) class UnitLengthConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[DW], src_dict: Dict[str, Any]) -> DW: + def from_dict(cls: Type[WM], src_dict: Dict[str, Any]) -> WM: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_mass_conversion.py b/kittycad/models/unit_mass_conversion.py index 9d2bf9516..0b50080b5 100644 --- a/kittycad/models/unit_mass_conversion.py +++ b/kittycad/models/unit_mass_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -MC = TypeVar("MC", bound="UnitMassConversion") +OK = TypeVar("OK", bound="UnitMassConversion") @attr.s(auto_attribs=True) class UnitMassConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MC], src_dict: Dict[str, Any]) -> MC: + def from_dict(cls: Type[OK], src_dict: Dict[str, Any]) -> OK: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_power_conversion.py b/kittycad/models/unit_power_conversion.py index 41da6ed2b..c3736bcca 100644 --- a/kittycad/models/unit_power_conversion.py +++ b/kittycad/models/unit_power_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -AV = TypeVar("AV", bound="UnitPowerConversion") +MU = TypeVar("MU", bound="UnitPowerConversion") @attr.s(auto_attribs=True) class UnitPowerConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[AV], src_dict: Dict[str, Any]) -> AV: + def from_dict(cls: Type[MU], src_dict: Dict[str, Any]) -> MU: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_pressure_conversion.py b/kittycad/models/unit_pressure_conversion.py index 5fada3748..93b876396 100644 --- a/kittycad/models/unit_pressure_conversion.py +++ b/kittycad/models/unit_pressure_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -BR = TypeVar("BR", bound="UnitPressureConversion") +OP = TypeVar("OP", bound="UnitPressureConversion") @attr.s(auto_attribs=True) class UnitPressureConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[BR], src_dict: Dict[str, Any]) -> BR: + def from_dict(cls: Type[OP], src_dict: Dict[str, Any]) -> OP: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_temperature_conversion.py b/kittycad/models/unit_temperature_conversion.py index 8d6893776..71603fd6f 100644 --- a/kittycad/models/unit_temperature_conversion.py +++ b/kittycad/models/unit_temperature_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -WM = TypeVar("WM", bound="UnitTemperatureConversion") +WW = TypeVar("WW", bound="UnitTemperatureConversion") @attr.s(auto_attribs=True) class UnitTemperatureConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WM], src_dict: Dict[str, Any]) -> WM: + def from_dict(cls: Type[WW], src_dict: Dict[str, Any]) -> WW: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_torque_conversion.py b/kittycad/models/unit_torque_conversion.py index 4d7f2852a..229f0dfe6 100644 --- a/kittycad/models/unit_torque_conversion.py +++ b/kittycad/models/unit_torque_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -OK = TypeVar("OK", bound="UnitTorqueConversion") +LV = TypeVar("LV", bound="UnitTorqueConversion") @attr.s(auto_attribs=True) class UnitTorqueConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OK], src_dict: Dict[str, Any]) -> OK: + def from_dict(cls: Type[LV], src_dict: Dict[str, Any]) -> LV: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/unit_volume_conversion.py b/kittycad/models/unit_volume_conversion.py index b84619fe2..2bdb09a63 100644 --- a/kittycad/models/unit_volume_conversion.py +++ b/kittycad/models/unit_volume_conversion.py @@ -9,7 +9,7 @@ from ..models.uuid import Uuid from ..types import UNSET, Unset -MU = TypeVar("MU", bound="UnitVolumeConversion") +II = TypeVar("II", bound="UnitVolumeConversion") @attr.s(auto_attribs=True) class UnitVolumeConversion: @@ -85,7 +85,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[MU], src_dict: Dict[str, Any]) -> MU: + def from_dict(cls: Type[II], src_dict: Dict[str, Any]) -> II: d = src_dict.copy() _completed_at = d.pop("completed_at", UNSET) completed_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/update_user.py b/kittycad/models/update_user.py index fdd4080fd..672e7ea18 100644 --- a/kittycad/models/update_user.py +++ b/kittycad/models/update_user.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -OP = TypeVar("OP", bound="UpdateUser") +FC = TypeVar("FC", bound="UpdateUser") @attr.s(auto_attribs=True) class UpdateUser: @@ -45,7 +45,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OP], src_dict: Dict[str, Any]) -> OP: + def from_dict(cls: Type[FC], src_dict: Dict[str, Any]) -> FC: d = src_dict.copy() company = d.pop("company", UNSET) diff --git a/kittycad/models/user.py b/kittycad/models/user.py index 102731afb..610e8e0eb 100644 --- a/kittycad/models/user.py +++ b/kittycad/models/user.py @@ -6,7 +6,7 @@ from ..types import UNSET, Unset -WW = TypeVar("WW", bound="User") +OA = TypeVar("OA", bound="User") @attr.s(auto_attribs=True) class User: @@ -81,7 +81,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[WW], src_dict: Dict[str, Any]) -> WW: + def from_dict(cls: Type[OA], src_dict: Dict[str, Any]) -> OA: d = src_dict.copy() company = d.pop("company", UNSET) diff --git a/kittycad/models/user_results_page.py b/kittycad/models/user_results_page.py index ac02a2566..7c43f1846 100644 --- a/kittycad/models/user_results_page.py +++ b/kittycad/models/user_results_page.py @@ -4,7 +4,7 @@ from ..types import UNSET, Unset -LV = TypeVar("LV", bound="UserResultsPage") +EI = TypeVar("EI", bound="UserResultsPage") @attr.s(auto_attribs=True) class UserResultsPage: @@ -33,7 +33,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[LV], src_dict: Dict[str, Any]) -> LV: + def from_dict(cls: Type[EI], src_dict: Dict[str, Any]) -> EI: d = src_dict.copy() from ..models.user import User items = cast(List[User], d.pop("items", UNSET)) diff --git a/kittycad/models/verification_token.py b/kittycad/models/verification_token.py index 2b58fc15c..528efc6b1 100644 --- a/kittycad/models/verification_token.py +++ b/kittycad/models/verification_token.py @@ -6,7 +6,7 @@ from ..types import UNSET, Unset -II = TypeVar("II", bound="VerificationToken") +CQ = TypeVar("CQ", bound="VerificationToken") @attr.s(auto_attribs=True) class VerificationToken: @@ -51,7 +51,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[II], src_dict: Dict[str, Any]) -> II: + def from_dict(cls: Type[CQ], src_dict: Dict[str, Any]) -> CQ: d = src_dict.copy() _created_at = d.pop("created_at", UNSET) created_at: Union[Unset, datetime.datetime] diff --git a/kittycad/models/volume.py b/kittycad/models/volume.py index a07a6d51a..2b758067a 100644 --- a/kittycad/models/volume.py +++ b/kittycad/models/volume.py @@ -5,7 +5,7 @@ from ..models.unit_volume import UnitVolume from ..types import UNSET, Unset -FC = TypeVar("FC", bound="Volume") +JE = TypeVar("JE", bound="Volume") @attr.s(auto_attribs=True) class Volume: @@ -31,7 +31,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[FC], src_dict: Dict[str, Any]) -> FC: + def from_dict(cls: Type[JE], src_dict: Dict[str, Any]) -> JE: d = src_dict.copy() _output_unit = d.pop("output_unit", UNSET) output_unit: Union[Unset, UnitVolume] diff --git a/kittycad/models/web_socket_request.py b/kittycad/models/web_socket_request.py index 8dbda928f..8fdc47410 100644 --- a/kittycad/models/web_socket_request.py +++ b/kittycad/models/web_socket_request.py @@ -9,7 +9,7 @@ from ..models.rtc_session_description import RtcSessionDescription from ..types import UNSET, Unset -OA = TypeVar("OA", bound="trickle_ice") +RD = TypeVar("RD", bound="trickle_ice") @attr.s(auto_attribs=True) class trickle_ice: @@ -34,7 +34,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[OA], src_dict: Dict[str, Any]) -> OA: + def from_dict(cls: Type[RD], src_dict: Dict[str, Any]) -> RD: d = src_dict.copy() _candidate = d.pop("candidate", UNSET) candidate: Union[Unset, RtcIceCandidateInit] @@ -73,7 +73,7 @@ def __contains__(self, key: str) -> bool: -EI = TypeVar("EI", bound="sdp_offer") +JW = TypeVar("JW", bound="sdp_offer") @attr.s(auto_attribs=True) class sdp_offer: @@ -98,7 +98,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[EI], src_dict: Dict[str, Any]) -> EI: + def from_dict(cls: Type[JW], src_dict: Dict[str, Any]) -> JW: d = src_dict.copy() _offer = d.pop("offer", UNSET) offer: Union[Unset, RtcSessionDescription] @@ -137,7 +137,7 @@ def __contains__(self, key: str) -> bool: -CQ = TypeVar("CQ", bound="modeling_cmd_req") +KZ = TypeVar("KZ", bound="modeling_cmd_req") @attr.s(auto_attribs=True) class modeling_cmd_req: @@ -167,7 +167,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[CQ], src_dict: Dict[str, Any]) -> CQ: + def from_dict(cls: Type[KZ], src_dict: Dict[str, Any]) -> KZ: d = src_dict.copy() _cmd = d.pop("cmd", UNSET) cmd: Union[Unset, ModelingCmd] @@ -214,7 +214,7 @@ def __contains__(self, key: str) -> bool: -JE = TypeVar("JE", bound="ping") +AS = TypeVar("AS", bound="ping") @attr.s(auto_attribs=True) class ping: @@ -234,7 +234,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[JE], src_dict: Dict[str, Any]) -> JE: + def from_dict(cls: Type[AS], src_dict: Dict[str, Any]) -> AS: d = src_dict.copy() type = d.pop("type", UNSET) @@ -265,7 +265,7 @@ def __contains__(self, key: str) -> bool: -RD = TypeVar("RD", bound="metrics_response") +IU = TypeVar("IU", bound="metrics_response") @attr.s(auto_attribs=True) class metrics_response: @@ -290,7 +290,7 @@ def to_dict(self) -> Dict[str, Any]: return field_dict @classmethod - def from_dict(cls: Type[RD], src_dict: Dict[str, Any]) -> RD: + def from_dict(cls: Type[IU], src_dict: Dict[str, Any]) -> IU: d = src_dict.copy() _metrics = d.pop("metrics", UNSET) metrics: Union[Unset, ClientMetrics] diff --git a/spec.json b/spec.json index 31973fc6f..3dfed92e5 100644 --- a/spec.json +++ b/spec.json @@ -1,10074 +1,10035 @@ { - "components": { - "responses": { - "Error": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Error" + "openapi": "3.0.3", + "info": { + "title": "KittyCAD API", + "description": "API server for KittyCAD", + "contact": { + "url": "https://kittycad.io", + "email": "api@kittycad.io" + }, + "version": "0.1.0" + }, + "paths": { + "/": { + "get": { + "tags": [ + "meta" + ], + "summary": "Get OpenAPI schema.", + "operationId": "get_schema", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": {} + } } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "description": "Error" + } } }, - "schemas": { - "AccountProvider": { - "description": "An account provider.", - "oneOf": [ - { - "description": "The Google account provider.", - "enum": [ - "google" - ], - "type": "string" - }, - { - "description": "The GitHub account provider.", - "enum": [ - "github" - ], - "type": "string" - } - ] - }, - "AiPluginApi": { - "description": "AI plugin api information.", - "properties": { - "is_user_authenticated": { - "default": false, - "description": "If the API is authenticated.", - "type": "boolean" - }, - "type": { - "allOf": [ - { - "$ref": "#/components/schemas/AiPluginApiType" + "/.well-known/ai-plugin.json": { + "get": { + "tags": [ + "meta", + "hidden" + ], + "summary": "Get AI plugin manifest.", + "operationId": "get_ai_plugin_manifest", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": "openapi", - "description": "The type of API." + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/AiPluginManifest" + } + } + } }, - "url": { - "description": "The url to the API's schema.", - "format": "uri", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "url" + } + } + }, + "/_meta/info": { + "get": { + "tags": [ + "meta", + "hidden" ], - "type": "object" - }, - "AiPluginApiType": { - "description": "AI plugin api type.", - "oneOf": [ - { - "description": "An OpenAPI specification.", - "enum": [ - "openapi" - ], - "type": "string" - } - ] - }, - "AiPluginAuth": { - "description": "AI plugin auth information.", - "properties": { - "authorization_type": { - "allOf": [ - { - "$ref": "#/components/schemas/AiPluginHttpAuthType" + "summary": "Get the metadata about our currently running server.", + "description": "This includes information on any of our other distributed systems it is connected to.\nYou must be a KittyCAD employee to perform this request.", + "operationId": "get_metadata", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The type of http authorization.", - "nullable": true - }, - "type": { - "allOf": [ - { - "$ref": "#/components/schemas/AiPluginAuthType" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Metadata" + } } - ], - "default": "none", - "description": "The type of authentication." - } - }, - "type": "object" - }, - "AiPluginAuthType": { - "description": "AI plugin auth type.", - "oneOf": [ - { - "description": "None.", - "enum": [ - "none" - ], - "type": "string" - }, - { - "description": "User http.", - "enum": [ - "user_http" - ], - "type": "string" + } }, - { - "description": "Service http.", - "enum": [ - "service_http" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "OAuth.", - "enum": [ - "oauth" - ], - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - ] - }, - "AiPluginHttpAuthType": { - "description": "AI plugin http auth type.", - "oneOf": [ + } + } + }, + "/ai/image-to-3d/{input_format}/{output_format}": { + "post": { + "tags": [ + "ai", + "beta", + "hidden" + ], + "summary": "Generate a 3D model from an image.", + "description": "This is an alpha endpoint. It will change in the future. The current output is honestly pretty bad. So if you find this endpoint, you get what you pay for, which currently is nothing. But in the future will be made a lot better.", + "operationId": "create_image_to_3d", + "parameters": [ { - "description": "Basic.", - "enum": [ - "basic" - ], - "type": "string" + "in": "path", + "name": "input_format", + "description": "The format of the image being converted.", + "required": true, + "schema": { + "$ref": "#/components/schemas/ImageType" + } }, { - "description": "Bearer.", - "enum": [ - "bearer" - ], - "type": "string" + "in": "path", + "name": "output_format", + "description": "The format the output file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } } - ] - }, - "AiPluginManifest": { - "description": "AI plugin manifest.\n\nThis is used for OpenAI's ChatGPT plugins. You can read more about them [here](https://platform.openai.com/docs/plugins/getting-started/plugin-manifest).", - "properties": { - "api": { - "allOf": [ - { - "$ref": "#/components/schemas/AiPluginApi" - } - ], - "description": "API specification." - }, - "auth": { - "allOf": [ - { - "$ref": "#/components/schemas/AiPluginAuth" + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" } - ], - "description": "Authentication schema." - }, - "contact_email": { - "description": "Email contact for safety/moderation reachout, support, and deactivation.", - "format": "email", - "type": "string" - }, - "description_for_human": { - "description": "Human-readable description of the plugin.", - "type": "string" - }, - "description_for_model": { - "description": "Description better tailored to the model, such as token context length considerations or keyword usage for improved plugin prompting.", - "type": "string" - }, - "legal_info_url": { - "description": "Redirect URL for users to view plugin information.", - "format": "uri", - "type": "string" - }, - "logo_url": { - "description": "URL used to fetch the plugin's logo.", - "format": "uri", - "type": "string" - }, - "name_for_human": { - "description": "Human-readable name, such as the full company name.", - "type": "string" - }, - "name_for_model": { - "description": "Name the model will used to target the plugin.", - "type": "string" + } }, - "schema_version": { - "description": "Manifest schema version.", - "type": "string" - } + "required": true }, - "required": [ - "api", - "auth", - "legal_info_url", - "logo_url" - ], - "type": "object" - }, - "Angle": { - "description": "An angle, with a specific unit.", - "properties": { - "unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitAngle" + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Mesh" + } } - ], - "description": "What unit is the measurement?" + } }, - "value": { - "description": "The size of the angle, measured in the chosen unit.", - "format": "double", - "type": "number" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "unit", - "value" - ], - "type": "object" + } }, - "AnnotationLineEnd": { - "description": "Annotation line end type", - "enum": [ - "none", - "arrow" + "options": { + "tags": [ + "hidden" ], - "type": "string" - }, - "AnnotationLineEndOptions": { - "description": "Options for annotation text", - "properties": { - "end": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationLineEnd" - } - ], - "description": "How to style the end of the annotation line." + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_image_to_3d", + "parameters": [ + { + "in": "path", + "name": "input_format", + "description": "The format of the image being converted.", + "required": true, + "schema": { + "$ref": "#/components/schemas/ImageType" + } }, - "start": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationLineEnd" - } - ], - "description": "How to style the start of the annotation line." + { + "in": "path", + "name": "output_format", + "description": "The format the output file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } } - }, - "required": [ - "end", - "start" ], - "type": "object" - }, - "AnnotationOptions": { - "description": "Options for annotations", - "properties": { - "color": { - "allOf": [ - { - "$ref": "#/components/schemas/Color" + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "Color to render the annotation", - "nullable": true + } }, - "line_ends": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationLineEndOptions" - } - ], - "description": "How to style the start and end of the line", - "nullable": true + "4XX": { + "$ref": "#/components/responses/Error" }, - "line_width": { - "description": "Width of the annotation's line", - "format": "float", - "nullable": true, - "type": "number" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/ai/text-to-3d/{output_format}": { + "post": { + "tags": [ + "ai", + "beta", + "hidden" + ], + "summary": "Generate a 3D model from text.", + "description": "This is an alpha endpoint. It will change in the future. The current output is honestly pretty bad. So if you find this endpoint, you get what you pay for, which currently is nothing. But in the future will be made a lot better.", + "operationId": "create_text_to_3d", + "parameters": [ + { + "in": "path", + "name": "output_format", + "description": "The format the output file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } }, - "position": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" + { + "in": "query", + "name": "prompt", + "description": "The prompt for the model.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "Position to put the annotation", - "nullable": true - }, - "text": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationTextOptions" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Mesh" + } } - ], - "description": "Text displayed on the annotation", - "nullable": true + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "type": "object" + } }, - "AnnotationTextAlignmentX": { - "description": "Horizontal Text aligment", - "enum": [ - "left", - "center", - "right" + "options": { + "tags": [ + "hidden" ], - "type": "string" - }, - "AnnotationTextAlignmentY": { - "description": "Vertical Text aligment", - "enum": [ - "bottom", - "center", - "top" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_text_to_3d", + "parameters": [ + { + "in": "path", + "name": "output_format", + "description": "The format the output file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } + } ], - "type": "string" - }, - "AnnotationTextOptions": { - "description": "Options for annotation text", - "properties": { - "point_size": { - "description": "Text font's point size", - "format": "uint32", - "minimum": 0, - "type": "integer" - }, - "text": { - "description": "Text displayed on the annotation", - "type": "string" - }, - "x": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationTextAlignmentX" + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "Alignment along the X axis" + } }, - "y": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationTextAlignmentY" - } - ], - "description": "Alignment along the Y axis" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "point_size", - "text", - "x", - "y" + } + } + }, + "/api-call-metrics": { + "get": { + "tags": [ + "api-calls", + "hidden" ], - "type": "object" - }, - "AnnotationType": { - "description": "The type of annotation", - "oneOf": [ - { - "description": "2D annotation type (screen or planar space)", - "enum": [ - "t2d" - ], - "type": "string" - }, + "summary": "Get API call metrics.", + "description": "This endpoint requires authentication by a KittyCAD employee. The API calls are grouped by the parameter passed.", + "operationId": "get_api_call_metrics", + "parameters": [ { - "description": "3D annotation type", - "enum": [ - "t3d" - ], - "type": "string" - } - ] - }, - "ApiCallQueryGroup": { - "description": "A response for a query on the API call table that is grouped by something.", - "properties": { - "count": { - "format": "int64", - "type": "integer" - }, - "query": { - "type": "string" + "in": "query", + "name": "group_by", + "description": "What field to group the metrics by.", + "required": true, + "schema": { + "$ref": "#/components/schemas/ApiCallQueryGroupBy" + } } - }, - "required": [ - "count", - "query" ], - "type": "object" - }, - "ApiCallQueryGroupBy": { - "description": "The field of an API call to group by.", - "oneOf": [ - { - "description": "The email of the user that requested the API call.", - "enum": [ - "email" - ], - "type": "string" - }, - { - "description": "The HTTP method of the API call.", - "enum": [ - "method" - ], - "type": "string" + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "title": "Array_of_ApiCallQueryGroup", + "type": "array", + "items": { + "$ref": "#/components/schemas/ApiCallQueryGroup" + } + } + } + } }, - { - "description": "The endpoint of the API call.", - "enum": [ - "endpoint" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/api-calls": { + "get": { + "tags": [ + "api-calls", + "hidden" + ], + "summary": "List API calls.", + "description": "This endpoint requires authentication by a KittyCAD employee. The API calls are returned in order of creation, with the most recently created API calls first.", + "operationId": "list_api_calls", + "parameters": [ { - "description": "The user ID of the user that requested the API call.", - "enum": [ - "user_id" - ], - "type": "string" + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, { - "description": "The origin of the API call. This is parsed from the `Origin` header.", - "enum": [ - "origin" - ], - "type": "string" + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, { - "description": "The IP address of the user making the API call.", - "enum": [ - "ip_address" - ], - "type": "string" + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } } - ] - }, - "ApiCallStatus": { - "description": "The status of an async API call.", - "oneOf": [ - { - "description": "The async API call is queued.", - "enum": [ - "queued" - ], - "type": "string" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" + } + } + } }, - { - "description": "The async API call was uploaded to be converted.", - "enum": [ - "uploaded" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + }, + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/api-calls/{id}": { + "get": { + "tags": [ + "api-calls", + "hidden" + ], + "summary": "Get details of an API call.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API call for the user.\nIf the user is not authenticated to view the specified API call, then it is not returned.\nOnly KittyCAD employees can view API calls for other users.", + "operationId": "get_api_call", + "parameters": [ { - "description": "The async API call is in progress.", - "enum": [ - "in_progress" - ], - "type": "string" + "in": "path", + "name": "id", + "description": "The ID of the API call.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiCallWithPrice" + } + } + } }, - { - "description": "The async API call has completed.", - "enum": [ - "completed" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "The async API call has failed.", - "enum": [ - "failed" - ], - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - ] - }, - "ApiCallWithPrice": { - "description": "An API call with the price.\n\nThis is a join of the `ApiCall` and `ApiCallPrice` tables.", - "properties": { - "completed_at": { - "description": "The date and time the API call completed billing.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The date and time the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "duration": { - "description": "The duration of the API call.", - "format": "duration", - "nullable": true, - "title": "int64", - "type": "integer" - }, - "email": { - "description": "The user's email address.", - "format": "email", - "type": "string" - }, - "endpoint": { - "description": "The endpoint requested by the API call.", - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier for the API call." - }, - "ip_address": { - "default": "", - "description": "The ip address of the origin.", - "format": "ip", - "title": "String", - "type": "string" - }, - "litterbox": { - "description": "If the API call was spawned from the litterbox or not.", - "nullable": true, - "type": "boolean" - }, - "method": { - "allOf": [ - { - "$ref": "#/components/schemas/Method" - } - ], - "description": "The HTTP method requsted by the API call." - }, - "minutes": { - "description": "The number of minutes the API call was billed for.", - "format": "int32", - "nullable": true, - "type": "integer" - }, - "origin": { - "description": "The origin of the API call.", - "type": "string" - }, - "price": { - "description": "The price of the API call.", - "format": "money-usd", - "nullable": true, - "title": "double", - "type": "number" - }, - "request_body": { - "description": "The request body sent by the API call.", - "nullable": true, - "type": "string" - }, - "request_query_params": { - "description": "The request query params sent by the API call.", - "type": "string" - }, - "response_body": { - "description": "The response body returned by the API call. We do not store this information if it is above a certain size.", - "nullable": true, - "type": "string" - }, - "started_at": { - "description": "The date and time the API call started billing.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status_code": { - "description": "The status code returned by the API call.", - "format": "int32", - "nullable": true, - "title": "int32", - "type": "integer" - }, - "stripe_invoice_item_id": { - "description": "The Stripe invoice item ID of the API call if it is billable.", - "type": "string" + } + } + }, + "/apps/github/callback": { + "get": { + "tags": [ + "apps", + "hidden" + ], + "summary": "Listen for callbacks to GitHub app authentication.", + "description": "This is different than OAuth 2.0 authentication for users. This endpoint grants access for KittyCAD to access user's repos.\nThe user doesn't need KittyCAD OAuth authorization for this endpoint, this is purely for the GitHub permissions to access repos.", + "operationId": "apps_github_callback", + "requestBody": { + "content": { + "application/json": { + "schema": {} + } }, - "token": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" + "required": true + }, + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The API token that made the API call." - }, - "updated_at": { - "description": "The date and time the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + } }, - "user_agent": { - "description": "The user agent of the request.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The ID of the user that made the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "method", - "token", - "updated_at", - "user_agent" + } + } + }, + "/apps/github/consent": { + "get": { + "tags": [ + "apps", + "hidden" ], - "type": "object" - }, - "ApiCallWithPriceResultsPage": { - "description": "A single page of results", - "properties": { - "items": { - "description": "list of items on this page of results", - "items": { - "$ref": "#/components/schemas/ApiCallWithPrice" + "summary": "Get the consent URL for GitHub app authentication.", + "description": "This is different than OAuth 2.0 authentication for users. This endpoint grants access for KittyCAD to access user's repos.\nThe user doesn't need KittyCAD OAuth authorization for this endpoint, this is purely for the GitHub permissions to access repos.", + "operationId": "apps_github_consent", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/AppClientInfo" + } + } + } }, - "next_page": { - "description": "token used to fetch the next page of results (if any)", - "nullable": true, - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "items" + } + } + }, + "/apps/github/webhook": { + "post": { + "tags": [ + "apps", + "hidden" ], - "type": "object" - }, - "ApiError": { - "description": "An error.", - "properties": { - "error_code": { - "allOf": [ - { - "$ref": "#/components/schemas/ErrorCode" + "summary": "Listen for GitHub webhooks.", + "description": "These come from the GitHub app.", + "operationId": "apps_github_webhook", + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" } - ], - "description": "The error code." + } }, - "message": { - "description": "The error message.", - "type": "string" - } + "required": true }, - "required": [ - "error_code", - "message" - ], - "type": "object" - }, - "ApiToken": { - "description": "An API token.\n\nThese are used to authenticate users with Bearer authentication.", - "properties": { - "created_at": { - "description": "The date and time the API token was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "id": { - "description": "The unique identifier for the API token.", - "type": "string" - }, - "is_valid": { - "description": "If the token is valid. We never delete API tokens, but we can mark them as invalid. We save them for ever to preserve the history of the API token.", - "type": "boolean" - }, - "token": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The API token itself." + } }, - "updated_at": { - "description": "The date and time the API token was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The ID of the user that owns the API token.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "is_valid", - "token", - "updated_at" - ], - "type": "object" + } }, - "ApiTokenResultsPage": { - "description": "A single page of results", - "properties": { - "items": { - "description": "list of items on this page of results", - "items": { - "$ref": "#/components/schemas/ApiToken" - }, - "type": "array" - }, - "next_page": { - "description": "token used to fetch the next page of results (if any)", - "nullable": true, - "type": "string" - } - }, - "required": [ - "items" + "options": { + "tags": [ + "hidden" ], - "type": "object" - }, - "AppClientInfo": { - "description": "Information about a third party app client.", - "properties": { - "url": { - "description": "The URL for consent.", - "type": "string" - } - }, - "type": "object" - }, - "AsyncApiCall": { - "description": "An async API call.", - "properties": { - "completed_at": { - "description": "The time and date the async API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the async API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_apps_github_webhook", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The unique identifier of the async API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": null, - "description": "The JSON input for the API call. These are determined by the endpoint that is run." - }, - "output": { - "description": "The JSON output for the API call. These are determined by the endpoint that is run.", - "nullable": true - }, - "started_at": { - "description": "The time and date the async API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + } }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the async API call." + "4XX": { + "$ref": "#/components/responses/Error" }, - "type": { - "allOf": [ - { - "$ref": "#/components/schemas/AsyncApiCallType" - } - ], - "description": "The type of async API call." + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/async/operations": { + "get": { + "tags": [ + "api-calls", + "hidden" + ], + "summary": "List async operations.", + "description": "For async file conversion operations, this endpoint does not return the contents of converted files (`output`). To get the contents use the `/async/operations/{id}` endpoint.\nThis endpoint requires authentication by a KittyCAD employee.", + "operationId": "list_async_operations", + "parameters": [ + { + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, - "updated_at": { - "description": "The time and date the async API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + { + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the async API call.", - "type": "string" + { + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } }, - "worker": { - "description": "The worker node that is performing or performed the async API call.", - "type": "string" + { + "in": "query", + "name": "status", + "description": "The status to filter by.", + "schema": { + "$ref": "#/components/schemas/ApiCallStatus" + } } - }, - "required": [ - "created_at", - "id", - "status", - "type", - "updated_at" ], - "type": "object" - }, - "AsyncApiCallOutput": { - "description": "The output from the async API call.", - "oneOf": [ - { - "description": "A file conversion.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "output_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileExportFormat" - } - ], - "description": "The output format of the file conversion." - }, - "output_format_options": { - "allOf": [ - { - "$ref": "#/components/schemas/OutputFormat" - } - ], - "description": "The output format options of the file conversion.", - "nullable": true - }, - "outputs": { - "additionalProperties": { - "format": "byte", - "title": "String", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "description": "The converted files (if multiple file conversion), if completed, base64 encoded. The key of the map is the path of the output file.", - "type": "object" - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file conversion." - }, - "src_format_options": { - "allOf": [ - { - "$ref": "#/components/schemas/InputFormat" - } - ], - "description": "The source format options of the file conversion.", - "nullable": true - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + } }, - "type": { - "enum": [ - "file_conversion" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "created_at", - "id", - "output_format", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/AsyncApiCallResultsPage" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + }, + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/async/operations/{id}": { + "get": { + "tags": [ + "api-calls" + ], + "summary": "Get an async operation.", + "description": "Get the status and output of an async operation.\nThis endpoint requires authentication by any KittyCAD user. It returns details of the requested async operation for the user.\nIf the user is not authenticated to view the specified async operation, then it is not returned.\nOnly KittyCAD employees with the proper access can view async operations for other users.", + "operationId": "get_async_operation", + "parameters": [ { - "description": "File center of mass.", - "properties": { - "center_of_mass": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "The resulting center of mass.", - "nullable": true - }, - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The output unit for the center of mass." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "in": "path", + "name": "id", + "description": "The ID of the async operation.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "file_center_of_mass" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" - }, - { - "description": "A file mass.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "mass": { - "description": "The resulting mass.", - "format": "double", - "nullable": true, - "type": "number" - }, - "material_density": { - "default": 0.0, - "description": "The material density as denoted by the user.", - "format": "double", - "type": "number" - }, - "material_density_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The material density unit." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The output unit for the mass." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/AsyncApiCallOutput" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/auth/email": { + "post": { + "tags": [ + "hidden" + ], + "summary": "Create an email verification request for a user.", + "operationId": "auth_email", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/EmailAuthenticationForm" + } + } + }, + "required": true + }, + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "file_mass" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "created_at", - "id", - "material_density_unit", - "output_unit", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/VerificationToken" + } + } + } }, - { - "description": "A file volume.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitVolume" - } - ], - "description": "The output unit for the volume." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." - }, - "type": { - "enum": [ - "file_volume" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_auth_email", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "volume": { - "description": "The resulting volume.", - "format": "double", - "nullable": true, - "type": "number" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/auth/email/callback": { + "get": { + "tags": [ + "hidden" + ], + "summary": "Listen for callbacks for email verification for users.", + "operationId": "auth_email_callback", + "parameters": [ { - "description": "A file density.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "density": { - "description": "The resulting density.", - "format": "double", - "nullable": true, - "type": "number" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "material_mass": { - "default": 0.0, - "description": "The material mass as denoted by the user.", - "format": "double", - "type": "number" - }, - "material_mass_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The material mass unit." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The output unit for the density." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "in": "query", + "name": "callback_url", + "description": "The URL to redirect back to after we have authenticated.", + "schema": { + "nullable": true, + "type": "string", + "format": "uri" + } + }, + { + "in": "query", + "name": "email", + "description": "The user's email.", + "required": true, + "schema": { + "type": "string", + "format": "email" + } + }, + { + "in": "query", + "name": "token", + "description": "The verification token.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "302": { + "description": "Temporary Redirect", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "file_density" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Set-Cookie": { + "description": "Set-Cookie header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "created_at", - "id", - "material_mass_unit", - "output_unit", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/file/center-of-mass": { + "post": { + "tags": [ + "file", + "beta" + ], + "summary": "Get CAD file center of mass.", + "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the cartesian co-ordinate in world space measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the center of mass of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_center_of_mass", + "parameters": [ { - "description": "A file surface area.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "in": "query", + "name": "output_unit", + "description": "The output unit for the center of mass.", + "schema": { + "$ref": "#/components/schemas/UnitLength" + } + }, + { + "in": "query", + "name": "src_format", + "description": "The format of the file.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } + } + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" + } + } + }, + "required": true + }, + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitArea" - } - ], - "description": "The output unit for the surface area." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." - }, - "surface_area": { - "description": "The resulting surface area.", - "format": "double", - "nullable": true, - "type": "number" - }, - "type": { - "enum": [ - "file_surface_area" - ], - "type": "string" - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "type", - "updated_at" - ], - "type": "object" - } - ] - }, - "AsyncApiCallResultsPage": { - "description": "A single page of results", - "properties": { - "items": { - "description": "list of items on this page of results", - "items": { - "$ref": "#/components/schemas/AsyncApiCall" - }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileCenterOfMass" + } + } + } }, - "next_page": { - "description": "token used to fetch the next page of results (if any)", - "nullable": true, - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "items" - ], - "type": "object" + } }, - "AsyncApiCallType": { - "description": "The type of async API call.", - "oneOf": [ - { - "description": "File conversion.", - "enum": [ - "file_conversion" - ], - "type": "string" - }, - { - "description": "File volume.", - "enum": [ - "file_volume" - ], - "type": "string" - }, - { - "description": "File center of mass.", - "enum": [ - "file_center_of_mass" - ], - "type": "string" - }, - { - "description": "File mass.", - "enum": [ - "file_mass" - ], - "type": "string" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_center_of_mass", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - { - "description": "File density.", - "enum": [ - "file_density" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "File surface area.", - "enum": [ - "file_surface_area" - ], - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - ] - }, - "Axis": { - "description": "Co-ordinate axis specifier.\n\nSee [cglearn.eu] for background reading.\n\n[cglearn.eu]: https://cglearn.eu/pub/computer-graphics/introduction-to-geometry#material-coordinate-systems-1", - "oneOf": [ + } + } + }, + "/file/conversion/{src_format}/{output_format}": { + "post": { + "tags": [ + "file" + ], + "summary": "Convert CAD file with defaults.", + "description": "If you wish to specify the conversion options, use the `/file/conversion` endpoint instead.\nConvert a CAD file from one format to another. If the file being converted is larger than 25MB, it will be performed asynchronously.\nIf the conversion is performed synchronously, the contents of the converted file (`output`) will be returned as a base64 encoded string.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_conversion", + "parameters": [ { - "description": "'Y' axis.", - "enum": [ - "y" - ], - "type": "string" + "in": "path", + "name": "output_format", + "description": "The format the file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } }, { - "description": "'Z' axis.", - "enum": [ - "z" - ], - "type": "string" - } - ] - }, - "AxisDirectionPair": { - "description": "An [`Axis`] paired with a [`Direction`].", - "properties": { - "axis": { - "allOf": [ - { - "$ref": "#/components/schemas/Axis" - } - ], - "description": "Axis specifier." - }, - "direction": { - "allOf": [ - { - "$ref": "#/components/schemas/Direction" - } - ], - "description": "Specifies which direction the axis is pointing." + "in": "path", + "name": "src_format", + "description": "The format of the file to convert.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } } - }, - "required": [ - "axis", - "direction" ], - "type": "object" - }, - "BillingInfo": { - "description": "The billing information for payments.", - "properties": { - "address": { - "allOf": [ - { - "$ref": "#/components/schemas/NewAddress" + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" } - ], - "description": "The address of the customer.", - "nullable": true - }, - "name": { - "description": "The name of the customer.", - "type": "string" + } }, - "phone": { - "default": "", - "description": "The phone for the customer.", - "format": "phone", - "title": "String", - "type": "string" - } + "required": true }, - "type": "object" - }, - "CacheMetadata": { - "description": "Metadata about our cache.\n\nThis is mostly used for internal purposes and debugging.", - "properties": { - "ok": { - "description": "If the cache returned an ok response from ping.", - "type": "boolean" + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileConversion" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "ok" - ], - "type": "object" + } }, - "CameraDragInteractionType": { - "description": "The type of camera drag interaction.", - "oneOf": [ - { - "description": "Camera pan", - "enum": [ - "pan" - ], - "type": "string" - }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_conversion", + "parameters": [ { - "description": "Camera rotate (revolve/orbit)", - "enum": [ - "rotate" - ], - "type": "string" + "in": "path", + "name": "output_format", + "description": "The format the file should be converted to.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileExportFormat" + } }, { - "description": "Camera zoom (increase or decrease distance to reference point center)", - "enum": [ - "zoom" - ], - "type": "string" + "in": "path", + "name": "src_format", + "description": "The format of the file to convert.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } } - ] - }, - "CardDetails": { - "description": "The card details of a payment method.", - "properties": { - "brand": { - "description": "Card brand.\n\nCan be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", - "type": "string" - }, - "checks": { - "allOf": [ - { - "$ref": "#/components/schemas/PaymentMethodCardChecks" + ], + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": {}, - "description": "Checks on Card address and CVC if provided." - }, - "country": { - "description": "Two-letter ISO code representing the country of the card.", - "type": "string" + } }, - "exp_month": { - "default": 0, - "description": "Two-digit number representing the card's expiration month.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "exp_year": { - "default": 0, - "description": "Four-digit number representing the card's expiration year.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/file/density": { + "post": { + "tags": [ + "file", + "beta" + ], + "summary": "Get CAD file density.", + "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint assumes if you are giving a material mass in a specific mass units, we return a density in mass unit per cubic measure unit.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the density of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_density", + "parameters": [ + { + "in": "query", + "name": "material_mass", + "description": "The material mass.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } }, - "fingerprint": { - "description": "Uniquely identifies this particular card number.", - "type": "string" + { + "in": "query", + "name": "material_mass_unit", + "description": "The unit of the material mass.", + "schema": { + "$ref": "#/components/schemas/UnitMass" + } }, - "funding": { - "description": "Card funding type.\n\nCan be `credit`, `debit`, `prepaid`, or `unknown`.", - "type": "string" + { + "in": "query", + "name": "output_unit", + "description": "The output unit for the density.", + "schema": { + "$ref": "#/components/schemas/UnitDensity" + } }, - "last4": { - "description": "The last four digits of the card.", - "type": "string" + { + "in": "query", + "name": "src_format", + "description": "The format of the file.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } } - }, - "type": "object" - }, - "CenterOfMass": { - "description": "The center of mass response.", - "properties": { - "center_of_mass": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" } - ], - "description": "The center of mass." + } }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The output unit for the center of mass." - } + "required": true }, - "required": [ - "center_of_mass", - "output_unit" - ], - "type": "object" - }, - "ClientMetrics": { - "description": "ClientMetrics contains information regarding the state of the peer.", - "properties": { - "rtc_frames_decoded": { - "description": "Counter of the number of WebRTC frames that the client has decoded during this session.", - "format": "uint64", - "minimum": 0, - "type": "integer" - }, - "rtc_frames_dropped": { - "description": "Counter of the number of WebRTC frames the client has dropped during this session.", - "format": "uint32", - "minimum": 0, - "type": "integer" - }, - "rtc_frames_per_second": { - "description": "Current number of frames being rendered per second. A good target is 60 frames per second, but it can fluctuate depending on network conditions.", - "format": "uint8", - "minimum": 0, - "type": "integer" - }, - "rtc_frames_received": { - "description": "Counter of the number of WebRTC frames that the client has received during this session.", - "format": "uint64", - "minimum": 0, - "type": "integer" - }, - "rtc_freeze_count": { - "description": "Number of times the WebRTC playback has frozen. This is usually due to network conditions.", - "format": "uint32", - "minimum": 0, - "type": "integer" - }, - "rtc_jitter_sec": { - "description": "Amount of \"jitter\" in the WebRTC session. Network latency is the time it takes a packet to traverse the network. The amount that the latency varies is the jitter. Video latency is the time it takes to render a frame sent by the server (including network latency). A low jitter means the video latency can be reduced without impacting smooth playback. High jitter means clients will increase video latency to ensure smooth playback.", - "format": "float", - "type": "number" + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileDensity" + } + } + } }, - "rtc_keyframes_decoded": { - "description": "Number of \"key frames\" decoded in the underlying h.264 stream. A key frame is an expensive (bandwidth-wise) \"full image\" of the video frame. Data after the keyframe become -- effectively -- \"diff\" operations on that key frame. The Engine will only send a keyframe if required, which is an indication that some of the \"diffs\" have been lost, usually an indication of poor network conditions. We like this metric to understand times when the connection has had to recover.", - "format": "uint32", - "minimum": 0, - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "rtc_total_freezes_duration_sec": { - "description": "Number of seconds of frozen video the user has been subjected to.", - "format": "float", - "type": "number" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "rtc_frames_decoded", - "rtc_frames_dropped", - "rtc_frames_per_second", - "rtc_frames_received", - "rtc_freeze_count", - "rtc_jitter_sec", - "rtc_keyframes_decoded", - "rtc_total_freezes_duration_sec" - ], - "type": "object" + } }, - "Cluster": { - "description": "Cluster information.", - "properties": { - "addr": { - "default": null, - "description": "The IP address of the cluster.", - "nullable": true, - "type": "string" - }, - "auth_timeout": { - "default": 0, - "description": "The auth timeout of the cluster.", - "format": "int64", - "type": "integer" - }, - "cluster_port": { - "default": 0, - "description": "The port of the cluster.", - "format": "int64", - "type": "integer" - }, - "name": { - "default": "", - "description": "The name of the cluster.", - "type": "string" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_density", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "tls_timeout": { - "default": 0, - "description": "The TLS timeout for the cluster.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "urls": { - "default": [], - "description": "The urls of the cluster.", - "items": { - "type": "string" - }, - "type": "array" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "type": "object" - }, - "CodeLanguage": { - "description": "The language code is written in.", - "oneOf": [ - { - "description": "The `go` programming language.", - "enum": [ - "go" - ], - "type": "string" - }, + } + } + }, + "/file/execute/{lang}": { + "post": { + "tags": [ + "executor", + "hidden" + ], + "summary": "Execute a KittyCAD program in a specific language.", + "operationId": "create_file_execution", + "parameters": [ { - "description": "The `python` programming language.", - "enum": [ - "python" - ], - "type": "string" + "in": "path", + "name": "lang", + "description": "The language of the code.", + "required": true, + "schema": { + "$ref": "#/components/schemas/CodeLanguage" + } }, { - "description": "The `node` programming language.", - "enum": [ - "node" - ], - "type": "string" + "in": "query", + "name": "output", + "description": "The output file we want to get the contents for (the paths are relative to where in litterbox it is being run). You can denote more than one file with a comma separated list of string paths.", + "schema": { + "nullable": true, + "type": "string" + } } - ] - }, - "CodeOutput": { - "description": "Output of the code being executed.", - "properties": { - "output_files": { - "description": "The contents of the files requested if they were passed.", - "items": { - "$ref": "#/components/schemas/OutputFile" + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" + } + } + }, + "required": true + }, + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CodeOutput" + } + } + } }, - "stderr": { - "default": "", - "description": "The stderr of the code.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "stdout": { - "default": "", - "description": "The stdout of the code.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "type": "object" + } }, - "Color": { - "description": "An RGBA color", - "properties": { - "a": { - "description": "Alpha", - "format": "float", - "type": "number" - }, - "b": { - "description": "Blue", - "format": "float", - "type": "number" - }, - "g": { - "description": "Green", - "format": "float", - "type": "number" - }, - "r": { - "description": "Red", - "format": "float", - "type": "number" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_execution", + "parameters": [ + { + "in": "path", + "name": "lang", + "description": "The language of the code.", + "required": true, + "schema": { + "$ref": "#/components/schemas/CodeLanguage" + } } - }, - "required": [ - "a", - "b", - "g", - "r" ], - "type": "object" - }, - "Connection": { - "description": "Metadata about a pub-sub connection.\n\nThis is mostly used for internal purposes and debugging.", - "properties": { - "auth_timeout": { - "default": 0, - "description": "The auth timeout of the server.", - "format": "int64", - "type": "integer" - }, - "cluster": { - "allOf": [ - { - "$ref": "#/components/schemas/Cluster" + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": { - "addr": null, - "auth_timeout": 0, - "cluster_port": 0, - "name": "", - "tls_timeout": 0, - "urls": [] - }, - "description": "Information about the cluster." + } }, - "config_load_time": { - "description": "The time the configuration was loaded.", - "format": "date-time", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "connections": { - "default": 0, - "description": "The number of connections to the server.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/file/mass": { + "post": { + "tags": [ + "file", + "beta" + ], + "summary": "Get CAD file mass.", + "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint assumes if you are giving a material density in a specific mass unit per cubic measure unit, we return a mass in mass units. The same mass units as passed in the material density.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the mass of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_mass", + "parameters": [ + { + "in": "query", + "name": "material_density", + "description": "The material density.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } }, - "cores": { - "default": 0, - "description": "The CPU core usage of the server.", - "format": "int64", - "type": "integer" + { + "in": "query", + "name": "material_density_unit", + "description": "The unit of the material density.", + "schema": { + "$ref": "#/components/schemas/UnitDensity" + } }, - "cpu": { - "default": 0.0, - "description": "The CPU usage of the server.", - "format": "double", - "type": "number" + { + "in": "query", + "name": "output_unit", + "description": "The output unit for the mass.", + "schema": { + "$ref": "#/components/schemas/UnitMass" + } }, - "gateway": { - "allOf": [ - { - "$ref": "#/components/schemas/Gateway" + { + "in": "query", + "name": "src_format", + "description": "The format of the file.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } + } + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" } - ], - "default": { - "auth_timeout": 0, - "host": "", - "name": "", - "port": 0, - "tls_timeout": 0 - }, - "description": "Information about the gateway." - }, - "git_commit": { - "default": "", - "description": "The git commit.", - "type": "string" - }, - "go": { - "default": "", - "description": "The go version.", - "type": "string" - }, - "gomaxprocs": { - "default": 0, - "description": "`GOMAXPROCS` of the server.", - "format": "int64", - "type": "integer" - }, - "host": { - "description": "The host of the server.", - "format": "ip", - "type": "string" - }, - "http_base_path": { - "default": "", - "description": "The http base path of the server.", - "type": "string" - }, - "http_host": { - "default": "", - "description": "The http host of the server.", - "type": "string" - }, - "http_port": { - "default": 0, - "description": "The http port of the server.", - "format": "int64", - "type": "integer" + } }, - "http_req_stats": { - "additionalProperties": { - "format": "int64", - "type": "integer" + "required": true + }, + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "description": "HTTP request statistics.", - "type": "object" - }, - "https_port": { - "default": 0, - "description": "The https port of the server.", - "format": "int64", - "type": "integer" - }, - "in_bytes": { - "default": 0, - "description": "The count of inbound bytes for the server.", - "format": "int64", - "type": "integer" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileMass" + } + } + } }, - "in_msgs": { - "default": 0, - "description": "The number of inbound messages for the server.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "jetstream": { - "allOf": [ - { - "$ref": "#/components/schemas/Jetstream" - } - ], - "default": { - "config": { - "domain": "", - "max_memory": 0, - "max_storage": 0, - "store_dir": "" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_mass", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "meta": { - "cluster_size": 0, - "leader": "", - "name": "" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "stats": { - "accounts": 0, - "api": { - "errors": 0, - "inflight": 0, - "total": 0 - }, - "ha_assets": 0, - "memory": 0, - "reserved_memory": 0, - "reserved_store": 0, - "store": 0 - } - }, - "description": "Jetstream information." - }, - "leaf": { - "allOf": [ - { - "$ref": "#/components/schemas/LeafNode" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": { - "auth_timeout": 0, - "host": "", - "port": 0, - "tls_timeout": 0 - }, - "description": "Information about leaf nodes." + } }, - "leafnodes": { - "default": 0, - "description": "The number of leaf nodes for the server.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "max_connections": { - "default": 0, - "description": "The max connections of the server.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/file/surface-area": { + "post": { + "tags": [ + "file", + "beta" + ], + "summary": "Get CAD file surface area.", + "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the square measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the surface area of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_surface_area", + "parameters": [ + { + "in": "query", + "name": "output_unit", + "description": "The output unit for the surface area.", + "schema": { + "$ref": "#/components/schemas/UnitArea" + } }, - "max_control_line": { - "default": 0, - "description": "The max control line of the server.", - "format": "int64", - "type": "integer" + { + "in": "query", + "name": "src_format", + "description": "The format of the file.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } + } + ], + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" + } + } }, - "max_payload": { - "default": 0, - "description": "The max payload of the server.", - "format": "int64", - "type": "integer" + "required": true + }, + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileSurfaceArea" + } + } + } }, - "max_pending": { - "default": 0, - "description": "The max pending of the server.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "mem": { - "default": 0, - "description": "The memory usage of the server.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_surface_area", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "now": { - "description": "The time now.", - "format": "date-time", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "out_bytes": { - "default": 0, - "description": "The count of outbound bytes for the server.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/file/volume": { + "post": { + "tags": [ + "file", + "beta" + ], + "summary": "Get CAD file volume.", + "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the cubic measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the volume of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", + "operationId": "create_file_volume", + "parameters": [ + { + "in": "query", + "name": "output_unit", + "description": "The output unit for the volume.", + "schema": { + "$ref": "#/components/schemas/UnitVolume" + } }, - "out_msgs": { - "default": 0, - "description": "The number of outbound messages for the server.", - "format": "int64", - "type": "integer" - }, - "ping_interval": { - "default": 0, - "description": "The ping interval of the server.", - "format": "int64", - "type": "integer" - }, - "ping_max": { - "default": 0, - "description": "The ping max of the server.", - "format": "int64", - "type": "integer" - }, - "port": { - "default": 0, - "description": "The port of the server.", - "format": "int64", - "type": "integer" - }, - "proto": { - "default": 0, - "description": "The protocol version.", - "format": "int64", - "type": "integer" - }, - "remotes": { - "default": 0, - "description": "The number of remotes for the server.", - "format": "int64", - "type": "integer" - }, - "routes": { - "default": 0, - "description": "The number of routes for the server.", - "format": "int64", - "type": "integer" - }, - "server_id": { - "default": "", - "description": "The server ID.", - "type": "string" - }, - "server_name": { - "default": "", - "description": "The server name.", - "type": "string" - }, - "slow_consumers": { - "default": 0, - "description": "The number of slow consumers for the server.", - "format": "int64", - "type": "integer" - }, - "start": { - "description": "When the server was started.", - "format": "date-time", - "type": "string" - }, - "subscriptions": { - "default": 0, - "description": "The number of subscriptions for the server.", - "format": "int64", - "type": "integer" - }, - "system_account": { - "default": "", - "description": "The system account.", - "type": "string" - }, - "tls_timeout": { - "default": 0, - "description": "The TLS timeout of the server.", - "format": "int64", - "type": "integer" - }, - "total_connections": { - "default": 0, - "description": "The total number of connections to the server.", - "format": "int64", - "type": "integer" - }, - "uptime": { - "default": "", - "description": "The uptime of the server.", - "type": "string" - }, - "version": { - "default": "", - "description": "The version of the service.", - "type": "string" - }, - "write_deadline": { - "default": 0, - "description": "The write deadline of the server.", - "format": "int64", - "type": "integer" + { + "in": "query", + "name": "src_format", + "description": "The format of the file.", + "required": true, + "schema": { + "$ref": "#/components/schemas/FileImportFormat" + } } - }, - "required": [ - "config_load_time", - "host", - "http_req_stats", - "now", - "start" ], - "type": "object" - }, - "CountryCode": { - "description": "An ISO-3166 alpha-2 country code. Always uppercase.", - "type": "string" - }, - "Coupon": { - "description": "The resource representing a Coupon.", - "properties": { - "amount_off": { - "description": "Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.", - "format": "money-usd", - "nullable": true, - "title": "double", - "type": "number" - }, - "deleted": { - "default": false, - "description": "Always true for a deleted object.", - "type": "boolean" - }, - "id": { - "description": "Unique identifier for the object.", - "type": "string" + "requestBody": { + "content": { + "application/octet-stream": { + "schema": { + "type": "string", + "format": "binary" + } + } }, - "percent_off": { - "description": "Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon.\n\nFor example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead.", - "format": "double", - "nullable": true, - "type": "number" - } + "required": true }, - "type": "object" - }, - "CreatedAtSortMode": { - "description": "Supported set of sort modes for scanning by created_at only.\n\nCurrently, we only support scanning in ascending order.", - "oneOf": [ - { - "description": "Sort in increasing order of \"created_at\".", - "enum": [ - "created_at_ascending" - ], - "type": "string" + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FileVolume" + } + } + } }, - { - "description": "Sort in decreasing order of \"created_at\".", - "enum": [ - "created_at_descending" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - ] - }, - "Currency": { - "description": "Currency is the list of supported currencies. Always lowercase.\n\nThis comes from the Stripe API docs: For more details see .", - "type": "string" + } }, - "CurveGetControlPoints": { - "description": "The response from the `CurveGetControlPoints` command.", - "properties": { - "control_points": { - "description": "Control points in the curve.", - "items": { - "$ref": "#/components/schemas/Point3d" - }, - "type": "array" - } - }, - "required": [ - "control_points" + "options": { + "tags": [ + "hidden" ], - "type": "object" - }, - "CurveGetEndPoints": { - "description": "Endpoints of a curve", - "properties": { - "end": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_file_volume", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "End" + } }, - "start": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Start" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "end", - "start" - ], - "type": "object" - }, - "CurveGetType": { - "description": "The response from the `CurveGetType` command.", - "properties": { - "curve_type": { - "allOf": [ - { - "$ref": "#/components/schemas/CurveType" - } - ], - "description": "Curve type" - } - }, - "required": [ - "curve_type" - ], - "type": "object" - }, - "CurveType": { - "description": "The type of Curve (embedded within path)", - "enum": [ - "line", - "arc", - "nurbs" + } + } + }, + "/hidden/ws/modeling": { + "options": { + "tags": [ + "hidden" ], - "type": "string" - }, - "Customer": { - "description": "The resource representing a payment \"Customer\".", - "properties": { - "address": { - "allOf": [ - { - "$ref": "#/components/schemas/NewAddress" + "summary": "Hidden endpoint for defining the modeling websocket types.", + "operationId": "hidden_ws_modeling_types", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WebSocketRequest" } - ], - "description": "The customer's address.", - "nullable": true - }, - "balance": { - "default": 0.0, - "description": "Current balance, if any, being stored on the customer in the payments service.\n\nIf negative, the customer has credit to apply to their next invoice. If positive, the customer has an amount owed that will be added to their next invoice. The balance does not refer to any unpaid invoices; it solely takes into account amounts that have yet to be successfully applied to any invoice. This balance is only taken into account as invoices are finalized.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "created_at": { - "description": "Time at which the object was created.", - "format": "date-time", - "type": "string" + } }, - "currency": { - "allOf": [ - { - "$ref": "#/components/schemas/Currency" + "required": true + }, + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": "usd", - "description": "Three-letter ISO code for the currency the customer can be charged in for recurring billing purposes." - }, - "delinquent": { - "default": false, - "description": "When the customer's latest invoice is billed by charging automatically, `delinquent` is `true` if the invoice's latest charge failed.\n\nWhen the customer's latest invoice is billed by sending an invoice, `delinquent` is `true` if the invoice isn't paid by its due date. If an invoice is marked uncollectible by dunning, `delinquent` doesn't get reset to `false`.", - "type": "boolean" - }, - "email": { - "description": "The customer's email address.", - "format": "email", - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "string" }, - "default": {}, - "description": "Set of key-value pairs.", - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WebSocketResponse" + } + } + } }, - "name": { - "description": "The customer's full name or business name.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "phone": { - "default": "", - "description": "The customer's phone number.", - "format": "phone", - "title": "String", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at" + } + } + }, + "/logout": { + "post": { + "tags": [ + "hidden" ], - "type": "object" - }, - "CustomerBalance": { - "description": "A balance for a user.\n\nThis holds information about the financial balance for the user.", - "properties": { - "created_at": { - "description": "The date and time the balance was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" + "summary": "This endpoint removes the session cookie for a user.", + "description": "This is used in logout scenarios.", + "operationId": "logout", + "responses": { + "204": { + "description": "resource updated", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Set-Cookie": { + "description": "Set-Cookie header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The unique identifier for the balance." - }, - "monthly_credits_remaining": { - "description": "The monthy credits remaining in the balance. This gets re-upped every month, but if the credits are not used for a month they do not carry over to the next month. It is a stable amount granted to the user per month.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "pre_pay_cash_remaining": { - "description": "The amount of pre-pay cash remaining in the balance. This number goes down as the user uses their pre-paid credits. The reason we track this amount is if a user ever wants to withdraw their pre-pay cash, we can use this amount to determine how much to give them. Say a user has $100 in pre-paid cash, their bill is worth, $50 after subtracting any other credits (like monthly etc.) Their bill is $50, their pre-pay cash remaining will be subtracted by 50 to pay the bill and their `pre_pay_credits_remaining` will be subtracted by 50 to pay the bill. This way if they want to withdraw money after, they can only withdraw $50 since that is the amount of cash they have remaining.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "pre_pay_credits_remaining": { - "description": "The amount of credits remaining in the balance. This is typically the amount of cash * some multiplier they get for pre-paying their account. This number lowers every time a bill is paid with the balance. This number increases every time a user adds funds to their balance. This may be through a subscription or a one off payment.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "total_due": { - "description": "This includes any outstanding, draft, or open invoices and any pending invoice items. This does not include any credits the user has on their account.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "updated_at": { - "description": "The date and time the balance was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + } }, - "user_id": { - "description": "The user ID the balance belongs to.", - "type": "string" - } - }, - "required": [ - "created_at", - "id", - "monthly_credits_remaining", - "pre_pay_cash_remaining", - "pre_pay_credits_remaining", - "total_due", - "updated_at" - ], - "type": "object" - }, - "Density": { - "description": "The density response.", - "properties": { - "density": { - "description": "The density.", - "format": "double", - "type": "number" + "4XX": { + "$ref": "#/components/responses/Error" }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The output unit for the density." + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "density", - "output_unit" - ], - "type": "object" + } }, - "DeviceAccessTokenRequestForm": { - "description": "The form for a device access token request.", - "properties": { - "client_id": { - "description": "The client ID.", - "format": "uuid", - "type": "string" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_logout", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "device_code": { - "description": "The device code.", - "format": "uuid", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "grant_type": { - "allOf": [ - { - "$ref": "#/components/schemas/OAuth2GrantType" - } - ], - "description": "The grant type." + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "client_id", - "device_code", - "grant_type" + } + } + }, + "/oauth2/device/auth": { + "post": { + "tags": [ + "oauth2", + "hidden" ], - "type": "object" - }, - "DeviceAuthRequestForm": { - "description": "The request parameters for the OAuth 2.0 Device Authorization Grant flow.", - "properties": { - "client_id": { - "description": "The client ID.", - "format": "uuid", - "type": "string" - } + "summary": "Start an OAuth 2.0 Device Authorization Grant.", + "description": "This endpoint is designed to be accessed from an *unauthenticated* API client. It generates and records a `device_code` and `user_code` which must be verified and confirmed prior to a token being granted.", + "operationId": "device_auth_request", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "$ref": "#/components/schemas/DeviceAuthRequestForm" + } + } + }, + "required": true }, - "required": [ - "client_id" - ], - "type": "object" - }, - "DeviceAuthVerifyParams": { - "description": "The request parameters to verify the `user_code` for the OAuth 2.0 Device Authorization Grant.", - "properties": { - "user_code": { - "description": "The user code.", - "type": "string" + "responses": { + "default": { + "description": "", + "content": { + "*/*": { + "schema": {} + } + } } - }, - "required": [ - "user_code" - ], - "type": "object" + } }, - "Direction": { - "description": "Specifies the sign of a co-ordinate axis.", - "oneOf": [ - { - "description": "Increasing numbers.", - "enum": [ - "positive" - ], - "type": "string" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_device_auth_request", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - { - "description": "Decreasing numbers.", - "enum": [ - "negative" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - ] - }, - "Discount": { - "description": "The resource representing a Discount.", - "properties": { - "coupon": { - "allOf": [ - { - "$ref": "#/components/schemas/Coupon" + } + } + }, + "/oauth2/device/confirm": { + "post": { + "tags": [ + "oauth2", + "hidden" + ], + "summary": "Confirm an OAuth 2.0 Device Authorization Grant.", + "description": "This endpoint is designed to be accessed by the user agent (browser), not the client requesting the token. So we do not actually return the token here; it will be returned in response to the poll on `/oauth2/device/token`.", + "operationId": "device_auth_confirm", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DeviceAuthVerifyParams" } - ], - "description": "The coupon that applied to create this discount." - } + } + }, + "required": true }, - "required": [ - "coupon" - ], - "type": "object" - }, - "EmailAuthenticationForm": { - "description": "The body of the form for email authentication.", - "properties": { - "callback_url": { - "description": "The URL to redirect back to after we have authenticated.", - "format": "uri", - "nullable": true, - "type": "string" + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "email": { - "description": "The user's email.", - "format": "email", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "email" - ], - "type": "object" + } }, - "EntityGetAllChildUuids": { - "description": "The response from the `EntityGetAllChildUuids` command.", - "properties": { - "entity_ids": { - "description": "The UUIDs of the child entities.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "entity_ids" + "options": { + "tags": [ + "hidden" ], - "type": "object" - }, - "EntityGetChildUuid": { - "description": "The response from the `EntityGetChildUuid` command.", - "properties": { - "entity_id": { - "description": "The UUID of the child entity.", - "format": "uuid", - "type": "string" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_device_auth_confirm", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "entity_id" + } + } + }, + "/oauth2/device/token": { + "post": { + "tags": [ + "oauth2", + "hidden" ], - "type": "object" - }, - "EntityGetNumChildren": { - "description": "The response from the `EntityGetNumChildren` command.", - "properties": { - "num": { - "description": "The number of children the entity has.", - "format": "uint32", - "minimum": 0, - "type": "integer" - } + "summary": "Request a device access token.", + "description": "This endpoint should be polled by the client until the user code is verified and the grant is confirmed.", + "operationId": "device_access_token", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "$ref": "#/components/schemas/DeviceAccessTokenRequestForm" + } + } + }, + "required": true }, - "required": [ - "num" - ], - "type": "object" - }, - "EntityGetParentId": { - "description": "The response from the `EntityGetParentId` command.", - "properties": { - "entity_id": { - "description": "The UUID of the parent entity.", - "format": "uuid", - "type": "string" + "responses": { + "default": { + "description": "", + "content": { + "*/*": { + "schema": {} + } + } } - }, - "required": [ - "entity_id" - ], - "type": "object" + } }, - "EntityType": { - "description": "The type of entity", - "enum": [ - "entity", - "object", - "path", - "curve", - "solid2d", - "solid3d", - "edge", - "face", - "plane" + "options": { + "tags": [ + "hidden" ], - "type": "string" - }, - "Environment": { - "description": "The environment the server is running in.", - "oneOf": [ - { - "description": "The development environment. This is for running locally.", - "enum": [ - "DEVELOPMENT" - ], - "type": "string" - }, - { - "description": "The preview environment. This is when PRs are created and a service is deployed for testing.", - "enum": [ - "PREVIEW" - ], - "type": "string" - }, - { - "description": "The production environment.", - "enum": [ - "PRODUCTION" - ], - "type": "string" - } - ] - }, - "Error": { - "description": "Error information from a response.", - "properties": { - "error_code": { - "type": "string" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_device_access_token", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "message": { - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "request_id": { - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "message", - "request_id" + } + } + }, + "/oauth2/device/verify": { + "get": { + "tags": [ + "oauth2", + "hidden" ], - "type": "object" - }, - "ErrorCode": { - "description": "The type of error sent by the KittyCAD API.", - "oneOf": [ - { - "description": "Graphics engine failed to complete request, consider retrying", - "enum": [ - "internal_engine" - ], - "type": "string" - }, - { - "description": "API failed to complete request, consider retrying", - "enum": [ - "internal_api" - ], - "type": "string" - }, - { - "description": "User requested something geometrically or graphically impossible. Don't retry this request, as it's inherently impossible. Instead, read the error message and change your request.", - "enum": [ - "bad_request" - ], - "type": "string" - }, - { - "description": "Client sent invalid JSON.", - "enum": [ - "invalid_json" - ], - "type": "string" - }, + "summary": "Verify an OAuth 2.0 Device Authorization Grant.", + "description": "This endpoint should be accessed in a full user agent (e.g., a browser). If the user is not logged in, we redirect them to the login page and use the `callback_url` parameter to get them to the UI verification form upon logging in. If they are logged in, we redirect them to the UI verification form on the website.", + "operationId": "device_auth_verify", + "parameters": [ { - "description": "Client sent invalid BSON.", - "enum": [ - "invalid_bson" - ], - "type": "string" + "in": "query", + "name": "user_code", + "description": "The user code.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "302": { + "description": "Temporary Redirect", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - { - "description": "Client sent a message which is not accepted over this protocol.", - "enum": [ - "wrong_protocol" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/oauth2/provider/{provider}/callback": { + "get": { + "tags": [ + "oauth2", + "hidden" + ], + "summary": "Listen for callbacks for the OAuth 2.0 provider.", + "operationId": "oauth2_provider_callback", + "parameters": [ { - "description": "Problem sending data between client and KittyCAD API.", - "enum": [ - "connection_problem" - ], - "type": "string" + "in": "path", + "name": "provider", + "description": "The provider.", + "required": true, + "schema": { + "$ref": "#/components/schemas/AccountProvider" + } }, { - "description": "Client sent a Websocket message type which the KittyCAD API does not handle.", - "enum": [ - "message_type_not_accepted" - ], - "type": "string" + "in": "query", + "name": "code", + "description": "The authorization code.", + "schema": { + "type": "string" + } }, { - "description": "Client sent a Websocket message intended for WebRTC but it was configured as a WebRTC connection.", - "enum": [ - "message_type_not_accepted_for_web_r_t_c" - ], - "type": "string" - } - ] - }, - "Export": { - "description": "The response from the `Export` endpoint.", - "properties": { - "files": { - "description": "The files that were exported.", - "items": { - "$ref": "#/components/schemas/ExportFile" - }, - "type": "array" + "in": "query", + "name": "state", + "description": "The state that we had passed in through the user consent URL.", + "schema": { + "type": "string" + } } - }, - "required": [ - "files" ], - "type": "object" - }, - "ExportFile": { - "description": "A file to be exported to the client.", - "properties": { - "contents": { - "description": "The contents of the file, base64 encoded.", - "format": "byte", - "title": "String", - "type": "string" + "responses": { + "302": { + "description": "Temporary Redirect", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Set-Cookie": { + "description": "Set-Cookie header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "name": { - "description": "The name of the file.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "contents", - "name" + } + } + }, + "/oauth2/provider/{provider}/consent": { + "get": { + "tags": [ + "oauth2", + "hidden" ], - "type": "object" - }, - "ExtendedUser": { - "description": "Extended user information.\n\nThis is mostly used for internal purposes. It returns a mapping of the user's information, including that of our third party services we use for users: MailChimp, Stripe, and Front", - "properties": { - "company": { - "description": "The user's company.", - "type": "string" + "summary": "Get the consent URL and other information for the OAuth 2.0 provider.", + "operationId": "oauth2_provider_consent", + "parameters": [ + { + "in": "path", + "name": "provider", + "description": "The provider.", + "required": true, + "schema": { + "$ref": "#/components/schemas/AccountProvider" + } }, - "created_at": { - "description": "The date and time the user was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" + { + "in": "query", + "name": "callback_url", + "description": "The URL to redirect back to after we have authenticated.", + "schema": { + "nullable": true, + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/OAuth2ClientInfo" + } + } + } }, - "discord": { - "description": "The user's Discord handle.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "email": { - "description": "The email address of the user.", - "format": "email", - "type": "string" - }, - "email_verified": { - "description": "The date and time the email address was verified.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "first_name": { - "description": "The user's first name.", - "type": "string" - }, - "front_id": { - "description": "The user's Front ID. This is mostly used for internal mapping.", - "nullable": true, - "type": "string" - }, - "github": { - "description": "The user's GitHub handle.", - "type": "string" - }, - "id": { - "description": "The unique identifier for the user.", - "type": "string" - }, - "image": { - "description": "The image avatar for the user. This is a URL.", - "format": "uri", - "title": "String", - "type": "string" - }, - "last_name": { - "description": "The user's last name.", - "type": "string" - }, - "mailchimp_id": { - "description": "The user's MailChimp ID. This is mostly used for internal mapping.", - "nullable": true, - "type": "string" - }, - "name": { - "description": "The name of the user. This is auto populated at first from the authentication provider (if there was a name). It can be updated by the user by updating their `first_name` and `last_name` fields.", - "type": "string" - }, - "phone": { - "default": "", - "description": "The user's phone number.", - "format": "phone", - "title": "String", - "type": "string" - }, - "stripe_id": { - "description": "The user's Stripe ID. This is mostly used for internal mapping.", - "nullable": true, - "type": "string" - }, - "updated_at": { - "description": "The date and time the user was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "image", - "updated_at" + } + } + }, + "/openai/openapi.json": { + "get": { + "tags": [ + "meta", + "hidden" ], - "type": "object" - }, - "ExtendedUserResultsPage": { - "description": "A single page of results", - "properties": { - "items": { - "description": "list of items on this page of results", - "items": { - "$ref": "#/components/schemas/ExtendedUser" + "summary": "Get AI plugin OpenAPI schema.", + "description": "This is the same as the OpenAPI schema, BUT it has some modifications to make it compatible with OpenAI. For example, descriptions must be < 300 chars.", + "operationId": "get_openai_schema", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": {} + } + } }, - "next_page": { - "description": "token used to fetch the next page of results (if any)", - "nullable": true, - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "items" + } + } + }, + "/ping": { + "get": { + "tags": [ + "meta" ], - "type": "object" - }, - "FailureWebSocketResponse": { - "description": "Unsuccessful Websocket response.", - "properties": { - "errors": { - "description": "The errors that occurred.", - "items": { - "$ref": "#/components/schemas/ApiError" + "summary": "Return pong.", + "operationId": "ping", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Pong" + } + } + } }, - "request_id": { - "description": "Which request this is a response to. If the request was a modeling command, this is the modeling command ID. If no request ID was sent, this will be null.", - "format": "uuid", - "nullable": true, - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "success": { - "description": "Always false", - "type": "boolean" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "errors", - "success" + } + } + }, + "/unit/conversion/angle/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FbxStorage": { - "description": "Describes the storage format of an FBX file.", - "oneOf": [ + "summary": "Convert angle units.", + "description": "Convert an angle unit value to another angle unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_angle_unit_conversion", + "parameters": [ { - "description": "ASCII FBX encoding.", - "enum": [ - "ascii" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitAngle" + } }, { - "description": "Binary FBX encoding.", - "enum": [ - "binary" - ], - "type": "string" - } - ] - }, - "FileCenterOfMass": { - "description": "A file center of mass result.", - "properties": { - "center_of_mass": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "The resulting center of mass.", - "nullable": true + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitAngle" + } }, - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The output unit for the center of mass." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitAngleConversion" + } } - ], - "description": "The status of the API call." + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "updated_at" + } + } + }, + "/unit/conversion/area/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FileConversion": { - "description": "A file conversion.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "summary": "Convert area units.", + "description": "Convert an area unit value to another area unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_area_unit_conversion", + "parameters": [ + { + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitArea" + } }, - "output_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileExportFormat" - } - ], - "description": "The output format of the file conversion." + { + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitArea" + } }, - "output_format_options": { - "allOf": [ - { - "$ref": "#/components/schemas/OutputFormat" + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The output format options of the file conversion.", - "nullable": true - }, - "outputs": { - "additionalProperties": { - "format": "byte", - "title": "String", - "type": "string" }, - "description": "The converted files (if multiple file conversion), if completed, base64 encoded. The key of the map is the path of the output file.", - "type": "object" - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file conversion." - }, - "src_format_options": { - "allOf": [ - { - "$ref": "#/components/schemas/InputFormat" - } - ], - "description": "The source format options of the file conversion.", - "nullable": true - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitAreaConversion" + } } - ], - "description": "The status of the API call." + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "output_format", - "src_format", - "status", - "updated_at" + } + } + }, + "/unit/conversion/current/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FileDensity": { - "description": "A file density result.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "density": { - "description": "The resulting density.", - "format": "double", - "nullable": true, - "type": "number" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "material_mass": { - "default": 0.0, - "description": "The material mass as denoted by the user.", - "format": "double", - "type": "number" - }, - "material_mass_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The material mass unit." + "summary": "Convert current units.", + "description": "Convert a current unit value to another current unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_current_unit_conversion", + "parameters": [ + { + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitCurrent" + } }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The output unit for the density." + { + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitCurrent" + } }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitCurrentConversion" + } } - ], - "description": "The status of the API call." + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "material_mass_unit", - "output_unit", - "src_format", - "status", - "updated_at" + } + } + }, + "/unit/conversion/energy/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FileExportFormat": { - "description": "The valid types of output file formats.", - "oneOf": [ + "summary": "Convert energy units.", + "description": "Convert a energy unit value to another energy unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_energy_unit_conversion", + "parameters": [ { - "description": "Autodesk Filmbox (FBX) format. ", - "enum": [ - "fbx" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitEnergy" + } }, { - "description": "Binary glTF 2.0.\n\nThis is a single binary with .glb extension.\n\nThis is better if you want a compressed format as opposed to the human readable glTF that lacks compression.", - "enum": [ - "glb" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitEnergy" + } }, { - "description": "glTF 2.0. Embedded glTF 2.0 (pretty printed).\n\nSingle JSON file with .gltf extension binary data encoded as base64 data URIs.\n\nThe JSON contents are pretty printed.\n\nIt is human readable, single file, and you can view the diff easily in a git commit.", - "enum": [ - "gltf" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitEnergyConversion" + } + } + } }, - { - "description": "The OBJ file format. It may or may not have an an attached material (mtl // mtllib) within the file, but we interact with it as if it does not.", - "enum": [ - "obj" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/unit/conversion/force/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" + ], + "summary": "Convert force units.", + "description": "Convert a force unit value to another force unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_force_unit_conversion", + "parameters": [ { - "description": "The PLY file format. ", - "enum": [ - "ply" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitForce" + } }, { - "description": "The STEP file format. ", - "enum": [ - "step" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitForce" + } }, { - "description": "The STL file format. ", - "enum": [ - "stl" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } } - ] - }, - "FileImportFormat": { - "description": "The valid types of source file formats.", - "oneOf": [ - { - "description": "Autodesk Filmbox (FBX) format. ", - "enum": [ - "fbx" - ], - "type": "string" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitForceConversion" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/unit/conversion/frequency/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" + ], + "summary": "Convert frequency units.", + "description": "Convert a frequency unit value to another frequency unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_frequency_unit_conversion", + "parameters": [ { - "description": "glTF 2.0.", - "enum": [ - "gltf" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitFrequency" + } }, { - "description": "The OBJ file format. It may or may not have an an attached material (mtl // mtllib) within the file, but we interact with it as if it does not.", - "enum": [ - "obj" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitFrequency" + } }, { - "description": "The PLY file format. ", - "enum": [ - "ply" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitFrequencyConversion" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/unit/conversion/length/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" + ], + "summary": "Convert length units.", + "description": "Convert a length unit value to another length unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_length_unit_conversion", + "parameters": [ { - "description": "SolidWorks part (SLDPRT) format.", - "enum": [ - "sldprt" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitLength" + } }, { - "description": "The STEP file format. ", - "enum": [ - "step" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitLength" + } }, { - "description": "The STL file format. ", - "enum": [ - "stl" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } } - ] - }, - "FileMass": { - "description": "A file mass result.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "mass": { - "description": "The resulting mass.", - "format": "double", - "nullable": true, - "type": "number" - }, - "material_density": { - "default": 0.0, - "description": "The material density as denoted by the user.", - "format": "double", - "type": "number" - }, - "material_density_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The material density unit." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The output unit for the mass." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitLengthConversion" + } } - ], - "description": "The status of the API call." + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "material_density_unit", - "output_unit", - "src_format", - "status", - "updated_at" + } + } + }, + "/unit/conversion/mass/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FileSurfaceArea": { - "description": "A file surface area result.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "summary": "Convert mass units.", + "description": "Convert a mass unit value to another mass unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_mass_unit_conversion", + "parameters": [ + { + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitMass" + } }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitArea" - } - ], - "description": "The output unit for the surface area." + { + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitMass" + } }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitMassConversion" + } } - ], - "description": "The status of the API call." - }, - "surface_area": { - "description": "The resulting surface area.", - "format": "double", - "nullable": true, - "type": "number" + } }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "updated_at" + } + } + }, + "/unit/conversion/power/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "FileSystemMetadata": { - "description": "Metadata about our file system.\n\nThis is mostly used for internal purposes and debugging.", - "properties": { - "ok": { - "description": "If the file system passed a sanity check.", - "type": "boolean" - } - }, - "required": [ - "ok" - ], - "type": "object" - }, - "FileVolume": { - "description": "A file volume result.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitVolume" - } - ], - "description": "The output unit for the volume." - }, - "src_format": { - "allOf": [ - { - "$ref": "#/components/schemas/FileImportFormat" - } - ], - "description": "The source format of the file." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "summary": "Convert power units.", + "description": "Convert a power unit value to another power unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_power_unit_conversion", + "parameters": [ + { + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitPower" + } }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + { + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitPower" + } }, - "volume": { - "description": "The resulting volume.", - "format": "double", - "nullable": true, - "type": "number" + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } } - }, - "required": [ - "created_at", - "id", - "output_unit", - "src_format", - "status", - "updated_at" ], - "type": "object" - }, - "Gateway": { - "description": "Gateway information.", - "properties": { - "auth_timeout": { - "default": 0, - "description": "The auth timeout of the gateway.", - "format": "int64", - "type": "integer" - }, - "host": { - "default": "", - "description": "The host of the gateway.", - "type": "string" - }, - "name": { - "default": "", - "description": "The name of the gateway.", - "type": "string" + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitPowerConversion" + } + } + } }, - "port": { - "default": 0, - "description": "The port of the gateway.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "tls_timeout": { - "default": 0, - "description": "The TLS timeout for the gateway.", - "format": "int64", - "type": "integer" - } - }, - "type": "object" - }, - "GetEntityType": { - "description": "The response from the `GetEntityType` command.", - "properties": { - "entity_type": { - "allOf": [ - { - "$ref": "#/components/schemas/EntityType" - } - ], - "description": "The type of the entity." + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "entity_type" + } + } + }, + "/unit/conversion/pressure/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "GltfPresentation": { - "description": "Describes the presentation style of the glTF JSON.", - "oneOf": [ - { - "description": "Condense the JSON into the smallest possible size.", - "enum": [ - "compact" - ], - "type": "string" - }, - { - "description": "Expand the JSON into a more human readable format.\n\nThis is the default setting.", - "enum": [ - "pretty" - ], - "type": "string" - } - ] - }, - "GltfStorage": { - "description": "Describes the storage format of a glTF 2.0 scene.", - "oneOf": [ + "summary": "Convert pressure units.", + "description": "Convert a pressure unit value to another pressure unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_pressure_unit_conversion", + "parameters": [ { - "description": "Binary glTF 2.0.\n\nThis is a single binary with .glb extension.", - "enum": [ - "binary" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitPressure" + } }, { - "description": "Standard glTF 2.0.\n\nThis is a JSON file with .gltf extension paired with a separate binary blob file with .bin extension.", - "enum": [ - "standard" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitPressure" + } }, { - "description": "Embedded glTF 2.0.\n\nSingle JSON file with .gltf extension binary data encoded as base64 data URIs.\n\nThis is the default setting.", - "enum": [ - "embedded" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } } - ] - }, - "HighlightSetEntity": { - "description": "The response from the `HighlightSetEntity` command.", - "properties": { - "entity_id": { - "description": "The UUID of the entity that was highlighted.", - "format": "uuid", - "nullable": true, - "type": "string" - }, - "sequence": { - "description": "If the client sent a sequence ID with its request, the backend sends it back.", - "format": "uint32", - "minimum": 0, - "nullable": true, - "type": "integer" - } - }, - "type": "object" - }, - "IceServer": { - "description": "Representation of an ICE server used for STUN/TURN Used to initiate WebRTC connections based on ", - "properties": { - "credential": { - "description": "Credentials for a given TURN server.", - "nullable": true, - "type": "string" - }, - "urls": { - "description": "URLs for a given STUN/TURN server. IceServer urls can either be a string or an array of strings But, we choose to always convert to an array of strings for consistency", - "items": { - "type": "string" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitPressureConversion" + } + } + } }, - "username": { - "description": "Username for a given TURN server.", - "nullable": true, - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "urls" + } + } + }, + "/unit/conversion/temperature/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "ImageFormat": { - "description": "Enum containing the variety of image formats snapshots may be exported to.", - "oneOf": [ + "summary": "Convert temperature units.", + "description": "Convert a temperature unit value to another temperature unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_temperature_unit_conversion", + "parameters": [ { - "description": ".png format", - "enum": [ - "png" - ], - "type": "string" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitTemperature" + } }, { - "description": ".jpeg format", - "enum": [ - "jpeg" - ], - "type": "string" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitTemperature" + } + }, + { + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } } - ] - }, - "ImageType": { - "description": "An enumeration.", - "enum": [ - "png", - "jpg" ], - "type": "string" - }, - "ImportFile": { - "description": "File to import into the current model", - "properties": { - "data": { - "description": "The raw bytes of the file", - "items": { - "format": "uint8", - "minimum": 0, - "type": "integer" + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitTemperatureConversion" + } + } + } }, - "path": { - "description": "The file's full path, including file extension.", - "type": "string" - } - }, - "required": [ - "data", - "path" - ], - "type": "object" - }, - "ImportFiles": { - "description": "Data from importing the files", - "properties": { - "object_id": { - "description": "ID of the imported 3D models within the scene.", - "format": "uuid", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "object_id" + } + } + }, + "/unit/conversion/torque/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" ], - "type": "object" - }, - "InputFormat": { - "description": "Input format specifier.", - "oneOf": [ + "summary": "Convert torque units.", + "description": "Convert a torque unit value to another torque unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_torque_unit_conversion", + "parameters": [ { - "description": "Autodesk Filmbox (FBX) format.", - "properties": { - "type": { - "enum": [ - "fbx" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitTorque" + } }, { - "description": "Binary glTF 2.0. We refer to this as glTF since that is how our customers refer to it, but this can also import binary glTF (glb).", - "properties": { - "type": { - "enum": [ - "gltf" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitTorque" + } }, { - "description": "Wavefront OBJ format.", - "properties": { - "coords": { - "allOf": [ - { - "$ref": "#/components/schemas/System" - } - ], - "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" - }, - "type": { - "enum": [ - "obj" - ], - "type": "string" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "units": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc.\n\nDefaults to meters." - } - }, - "required": [ - "coords", - "type", - "units" - ], - "type": "object" - }, - { - "description": "The PLY Polygon File Format.", - "properties": { - "coords": { - "allOf": [ - { - "$ref": "#/components/schemas/System" - } - ], - "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "ply" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "units": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc." + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "coords", - "type", - "units" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitTorqueConversion" + } + } + } }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/unit/conversion/volume/{input_unit}/{output_unit}": { + "get": { + "tags": [ + "unit" + ], + "summary": "Convert volume units.", + "description": "Convert a volume unit value to another volume unit value. This is a nice endpoint to use for helper functions.", + "operationId": "get_volume_unit_conversion", + "parameters": [ { - "description": "SolidWorks part (SLDPRT) format.", - "properties": { - "type": { - "enum": [ - "sldprt" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "in": "path", + "name": "input_unit", + "description": "The source format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitVolume" + } }, { - "description": "ISO 10303-21 (STEP) format.", - "properties": { - "type": { - "enum": [ - "step" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "in": "path", + "name": "output_unit", + "description": "The output format of the unit.", + "required": true, + "schema": { + "$ref": "#/components/schemas/UnitVolume" + } }, { - "description": "*ST**ereo**L**ithography format.", - "properties": { - "coords": { - "allOf": [ - { - "$ref": "#/components/schemas/System" - } - ], - "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + "in": "query", + "name": "value", + "description": "The initial value.", + "required": true, + "schema": { + "type": "number", + "format": "double" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "stl" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "units": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "coords", - "type", - "units" - ], - "type": "object" - } - ] - }, - "Invoice": { - "description": "An invoice.", - "properties": { - "amount_due": { - "default": 0.0, - "description": "Final amount due at this time for this invoice.\n\nIf the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "amount_paid": { - "default": 0.0, - "description": "The amount, in USD, that was paid.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "amount_remaining": { - "default": 0.0, - "description": "The amount remaining, in USD, that is due.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "attempt_count": { - "default": 0, - "description": "Number of payment attempts made for this invoice, from the perspective of the payment retry schedule.\n\nAny payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule.", - "format": "uint64", - "minimum": 0, - "type": "integer" - }, - "attempted": { - "default": false, - "description": "Whether an attempt has been made to pay the invoice.\n\nAn invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.", - "type": "boolean" - }, - "created_at": { - "description": "Time at which the object was created.", - "format": "date-time", - "type": "string" - }, - "currency": { - "allOf": [ - { - "$ref": "#/components/schemas/Currency" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UnitVolumeConversion" + } } - ], - "default": "usd", - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase." - }, - "customer_email": { - "description": "The email address for the customer. Until the invoice is finalized, this field will equal customer.email. Once the invoice is finalized, this field will no longer be updated.", - "format": "email", - "type": "string" - }, - "customer_id": { - "description": "Customer ID. The unique identifier for the customer this invoice belongs to. This is the customer ID in the payments service, not our database customer ID.", - "type": "string" - }, - "default_payment_method": { - "description": "Default payment method.", - "type": "string" + } }, - "description": { - "description": "Description of the invoice.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "discounts": { - "description": "The discounts applied to the invoice. This is an array of discount objects.", - "items": { - "$ref": "#/components/schemas/Discount" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user": { + "get": { + "tags": [ + "users" + ], + "summary": "Get your user.", + "description": "Get the user information for the authenticated user.\nAlternatively, you can also use the `/users/me` endpoint.", + "operationId": "get_user_self", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "type": "array" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/User" + } + } + } }, - "id": { - "description": "Unique identifier for the object.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "lines": { - "description": "The individual line items that make up the invoice.\n\n`lines` is sorted as follows: invoice items in reverse chronological order, followed by the subscription, if any.", - "items": { - "$ref": "#/components/schemas/InvoiceLineItem" - }, - "type": "array" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "put": { + "tags": [ + "users" + ], + "summary": "Update your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It updates information about the authenticated user.", + "operationId": "update_user_self", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UpdateUser" + } + } }, - "metadata": { - "additionalProperties": { - "type": "string" + "required": true + }, + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } }, - "default": {}, - "description": "Set of key-value pairs.", - "type": "object" - }, - "number": { - "description": "A unique, identifying string that appears on emails sent to the customer for this invoice.", - "type": "string" - }, - "paid": { - "default": false, - "description": "Whether payment was successfully collected for this invoice.\n\nAn invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.", - "type": "boolean" - }, - "pdf": { - "description": "The link to download the PDF for the invoice.", - "format": "uri", - "nullable": true, - "type": "string" - }, - "receipt_number": { - "description": "This is the transaction number that appears on email receipts sent for this invoice.", - "type": "string" - }, - "statement_descriptor": { - "description": "Extra information about an invoice for the customer's credit card statement.", - "type": "string" - }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/InvoiceStatus" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/User" + } } - ], - "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`.\n\n[Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview).", - "nullable": true - }, - "subtotal": { - "default": 0.0, - "description": "Total of all subscriptions, invoice items, and prorations on the invoice before any invoice level discount or tax is applied.\n\nItem discounts are already incorporated.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "tax": { - "default": 0.0, - "description": "The amount of tax on this invoice.\n\nThis is the sum of all the tax amounts on this invoice.", - "format": "money-usd", - "title": "double", - "type": "number" + } }, - "total": { - "default": 0.0, - "description": "Total after discounts and taxes.", - "format": "money-usd", - "title": "double", - "type": "number" + "4XX": { + "$ref": "#/components/responses/Error" }, - "url": { - "description": "The URL for the hosted invoice page, which allows customers to view and pay an invoice.", - "format": "uri", - "nullable": true, - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "created_at" - ], - "type": "object" + } }, - "InvoiceLineItem": { - "description": "An invoice line item.", - "properties": { - "amount": { - "default": 0.0, - "description": "The amount, in USD.", - "format": "money-usd", - "title": "double", - "type": "number" - }, - "currency": { - "allOf": [ - { - "$ref": "#/components/schemas/Currency" + "delete": { + "tags": [ + "users" + ], + "summary": "Delete your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It deletes the authenticated user from KittyCAD's database.\nThis call will only succeed if all invoices associated with the user have been paid in full and there is no outstanding balance.", + "operationId": "delete_user_self", + "responses": { + "204": { + "description": "successful deletion", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": "usd", - "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase." - }, - "description": { - "description": "The description.", - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "type": "string" + } }, - "invoice_item": { - "description": "The ID of the invoice item associated with this line item if any.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "default": {}, - "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object.\n\nSet of key-value pairs.", - "type": "object" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "type": "object" + } }, - "InvoiceStatus": { - "description": "An enum representing the possible values of an `Invoice`'s `status` field.", - "oneOf": [ - { - "description": "Deleted.", - "enum": [ - "deleted" - ], - "type": "string" - }, - { - "description": "Draft.", - "enum": [ - "draft" - ], - "type": "string" + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_user_self", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - { - "description": "Open.", - "enum": [ - "open" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/api-calls": { + "get": { + "tags": [ + "api-calls" + ], + "summary": "List API calls for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns the API calls for the authenticated user.\nThe API calls are returned in order of creation, with the most recently created API calls first.", + "operationId": "user_list_api_calls", + "parameters": [ { - "description": "Paid.", - "enum": [ - "paid" - ], - "type": "string" + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, { - "description": "Uncollectible.", - "enum": [ - "uncollectible" - ], - "type": "string" + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, { - "description": "Void.", - "enum": [ - "void" - ], - "type": "string" + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } } - ] - }, - "Jetstream": { - "description": "Jetstream information.", - "properties": { - "config": { - "allOf": [ - { - "$ref": "#/components/schemas/JetstreamConfig" - } - ], - "default": { - "domain": "", - "max_memory": 0, - "max_storage": 0, - "store_dir": "" - }, - "description": "The Jetstream config." - }, - "meta": { - "allOf": [ - { - "$ref": "#/components/schemas/MetaClusterInfo" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": { - "cluster_size": 0, - "leader": "", - "name": "" }, - "description": "Meta information about the cluster." - }, - "stats": { - "allOf": [ - { - "$ref": "#/components/schemas/JetstreamStats" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" + } } - ], - "default": { - "accounts": 0, - "api": { - "errors": 0, - "inflight": 0, - "total": 0 - }, - "ha_assets": 0, - "memory": 0, - "reserved_memory": 0, - "reserved_store": 0, - "store": 0 - }, - "description": "Jetstream statistics." - } - }, - "type": "object" - }, - "JetstreamApiStats": { - "description": "Jetstream API statistics.", - "properties": { - "errors": { - "default": 0, - "description": "The number of errors.", - "format": "int64", - "type": "integer" + } }, - "inflight": { - "default": 0, - "description": "The number of inflight requests.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "total": { - "default": 0, - "description": "The number of requests.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" } }, - "type": "object" - }, - "JetstreamConfig": { - "description": "Jetstream configuration.", - "properties": { - "domain": { - "default": "", - "description": "The domain.", - "type": "string" - }, - "max_memory": { - "default": 0, - "description": "The max memory.", - "format": "int64", - "type": "integer" - }, - "max_storage": { - "default": 0, - "description": "The max storage.", - "format": "int64", - "type": "integer" - }, - "store_dir": { - "default": "", - "description": "The store directory.", - "type": "string" + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/user/api-calls/{id}": { + "get": { + "tags": [ + "api-calls" + ], + "summary": "Get an API call for a user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API call for the user.", + "operationId": "get_api_call_for_user", + "parameters": [ + { + "in": "path", + "name": "id", + "description": "The ID of the API call.", + "required": true, + "schema": { + "type": "string" + } } - }, - "type": "object" - }, - "JetstreamStats": { - "description": "Jetstream statistics.", - "properties": { - "accounts": { - "default": 0, - "description": "The number of accounts.", - "format": "int64", - "type": "integer" - }, - "api": { - "allOf": [ - { - "$ref": "#/components/schemas/JetstreamApiStats" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "default": { - "errors": 0, - "inflight": 0, - "total": 0 }, - "description": "API stats." - }, - "ha_assets": { - "default": 0, - "description": "The number of HA assets.", - "format": "int64", - "type": "integer" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiCallWithPrice" + } + } + } }, - "memory": { - "default": 0, - "description": "The memory used by the Jetstream server.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "reserved_memory": { - "default": 0, - "description": "The reserved memory for the Jetstream server.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/api-tokens": { + "get": { + "tags": [ + "api-tokens" + ], + "summary": "List API tokens for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns the API tokens for the authenticated user.\nThe API tokens are returned in order of creation, with the most recently created API tokens first.", + "operationId": "list_api_tokens_for_user", + "parameters": [ + { + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, - "reserved_store": { - "default": 0, - "description": "The reserved storage for the Jetstream server.", - "format": "int64", - "type": "integer" + { + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, - "store": { - "default": 0, - "description": "The storage used by the Jetstream server.", - "format": "int64", - "type": "integer" + { + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } } - }, - "type": "object" - }, - "LeafNode": { - "description": "Leaf node information.", - "properties": { - "auth_timeout": { - "default": 0, - "description": "The auth timeout of the leaf node.", - "format": "int64", - "type": "integer" - }, - "host": { - "default": "", - "description": "The host of the leaf node.", - "type": "string" + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiTokenResultsPage" + } + } + } }, - "port": { - "default": 0, - "description": "The port of the leaf node.", - "format": "int64", - "type": "integer" + "4XX": { + "$ref": "#/components/responses/Error" }, - "tls_timeout": { - "default": 0, - "description": "The TLS timeout for the leaf node.", - "format": "int64", - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" } }, - "type": "object" + "x-dropshot-pagination": { + "required": [] + } }, - "Mass": { - "description": "The mass response.", - "properties": { - "mass": { - "description": "The mass.", - "format": "double", - "type": "number" - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" + "post": { + "tags": [ + "api-tokens" + ], + "summary": "Create a new API token for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It creates a new API token for the authenticated user.", + "operationId": "create_api_token_for_user", + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiToken" + } } - ], - "description": "The output unit for the mass." + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "mass", - "output_unit" - ], - "type": "object" + } }, - "Mesh": { - "properties": { - "mesh": { - "type": "string" - } - }, - "required": [ - "mesh" + "options": { + "tags": [ + "hidden" ], - "type": "object" - }, - "MetaClusterInfo": { - "description": "Jetstream statistics.", - "properties": { - "cluster_size": { - "default": 0, - "description": "The size of the cluster.", - "format": "int64", - "type": "integer" + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_api_token_for_user", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - "leader": { - "default": "", - "description": "The leader of the cluster.", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, - "name": { - "default": "", - "description": "The name of the cluster.", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "type": "object" - }, - "Metadata": { - "description": "Metadata about our currently running server.\n\nThis is mostly used for internal purposes and debugging.", - "properties": { - "cache": { - "allOf": [ - { - "$ref": "#/components/schemas/CacheMetadata" - } - ], - "description": "Metadata about our cache." - }, - "environment": { - "allOf": [ - { - "$ref": "#/components/schemas/Environment" + } + } + }, + "/user/api-tokens/{token}": { + "get": { + "tags": [ + "api-tokens" + ], + "summary": "Get an API token for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API token for the user.", + "operationId": "get_api_token_for_user", + "parameters": [ + { + "in": "path", + "name": "token", + "description": "The API token.", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - ], - "description": "The environment we are running in." - }, - "fs": { - "allOf": [ - { - "$ref": "#/components/schemas/FileSystemMetadata" + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiToken" + } } - ], - "description": "Metadata about our file system." - }, - "git_hash": { - "description": "The git hash of the server.", - "type": "string" + } }, - "point_e": { - "allOf": [ - { - "$ref": "#/components/schemas/PointEMetadata" - } - ], - "description": "Metadata about our point-e instance." + "4XX": { + "$ref": "#/components/responses/Error" }, - "pubsub": { - "allOf": [ - { - "$ref": "#/components/schemas/Connection" - } - ], - "description": "Metadata about our pub-sub connection." + "5XX": { + "$ref": "#/components/responses/Error" } - }, - "required": [ - "cache", - "environment", - "fs", - "git_hash", - "point_e", - "pubsub" - ], - "type": "object" + } }, - "Method": { - "description": "The Request Method (VERB)\n\nThis type also contains constants for a number of common HTTP methods such as GET, POST, etc.\n\nCurrently includes 8 variants representing the 8 methods defined in [RFC 7230](https://tools.ietf.org/html/rfc7231#section-4.1), plus PATCH, and an Extension variant for all extensions.", - "oneOf": [ - { - "description": "The `OPTIONS` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.2.1).", - "enum": [ - "OPTIONS" - ], - "type": "string" - }, - { - "description": "The `GET` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", - "enum": [ - "GET" - ], - "type": "string" - }, - { - "description": "The `POST` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", - "enum": [ - "POST" - ], - "type": "string" - }, + "delete": { + "tags": [ + "api-tokens" + ], + "summary": "Delete an API token for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It deletes the requested API token for the user.\nThis endpoint does not actually delete the API token from the database. It merely marks the token as invalid. We still want to keep the token in the database for historical purposes.", + "operationId": "delete_api_token_for_user", + "parameters": [ { - "description": "The `PUT` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", - "enum": [ - "PUT" - ], - "type": "string" + "in": "path", + "name": "token", + "description": "The API token.", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + } + } + ], + "responses": { + "204": { + "description": "successful deletion", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + } + } }, - { - "description": "The `DELETE` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.5).", - "enum": [ - "DELETE" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_api_token_for_user", + "parameters": [ { - "description": "The `HEAD` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.2).", - "enum": [ - "HEAD" - ], - "type": "string" - }, - { - "description": "The `TRACE` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3).", - "enum": [ - "TRACE" - ], - "type": "string" - }, - { - "description": "The `CONNECT` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.6).", - "enum": [ - "CONNECT" - ], - "type": "string" - }, - { - "description": "The `PATCH` method as defined in [RFC 5789](https://tools.ietf.org/html/rfc5789).", - "enum": [ - "PATCH" - ], - "type": "string" - }, - { - "description": "A catch all.", - "enum": [ - "EXTENSION" - ], - "type": "string" + "in": "path", + "name": "token", + "description": "The API token.", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + } } - ] - }, - "ModelingCmd": { - "description": "Commands that the KittyCAD engine can execute.", - "oneOf": [ - { - "description": "Start a path.", - "properties": { - "type": { - "enum": [ - "start_path" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" - }, - { - "description": "Move the path's \"pen\".", - "properties": { - "path": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmdId" - } - ], - "description": "The ID of the command which created the path." + ], + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "to": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Where the path's pen should be." + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "move_path_pen" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "path", - "to", - "type" - ], - "type": "object" + } }, - { - "description": "Extend a path by adding a new segment which starts at the path's \"pen\". If no \"pen\" location has been set before (via `MovePen`), then the pen is at the origin.", - "properties": { - "path": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmdId" - } - ], - "description": "The ID of the command which created the path." + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/extended": { + "get": { + "tags": [ + "users" + ], + "summary": "Get extended information about your user.", + "description": "Get the user information for the authenticated user.\nAlternatively, you can also use the `/users-extended/me` endpoint.", + "operationId": "get_user_self_extended", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "segment": { - "allOf": [ - { - "$ref": "#/components/schemas/PathSegment" - } - ], - "description": "Segment to append to the path. This segment will implicitly begin at the current \"pen\" location." + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "extend_path" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "path", - "segment", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ExtendedUser" + } + } + } }, - { - "description": "Extrude a 2D solid.", - "properties": { - "cap": { - "description": "Whether to cap the extrusion with a face, or not. If true, the resulting solid will be closed on all sides, like a dice. If false, it will be open on one side, like a drinking glass.", - "type": "boolean" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/front-hash": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "Get your user's front verification hash.", + "description": "This info is sent to front when initialing the front chat, it prevents impersonations using js hacks in the browser", + "operationId": "get_user_front_hash_self", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "distance": { - "description": "How far off the plane to extrude", - "format": "double", - "type": "number" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "target": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmdId" - } - ], - "description": "Which sketch to extrude. Must be a closed 2D solid." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "extrude" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "cap", - "distance", - "target", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "title": "String", + "type": "string" + } + } + } }, - { - "description": "Closes a path, converting it to a 2D solid.", - "properties": { - "path_id": { - "description": "Which path to close.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "close_path" - ], - "type": "string" - } - }, - "required": [ - "path_id", - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "Camera drag started.", - "properties": { - "interaction": { - "allOf": [ - { - "$ref": "#/components/schemas/CameraDragInteractionType" - } - ], - "description": "The type of camera drag interaction." + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/onboarding": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "Get your user's onboarding status.", + "description": "Checks key part of their api usage to determine their onboarding progress", + "operationId": "get_user_onboarding_self", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "camera_drag_start" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The initial mouse position." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "interaction", - "type", - "window" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Onboarding" + } + } + } }, - { - "description": "Camera drag continued.", - "properties": { - "interaction": { - "allOf": [ - { - "$ref": "#/components/schemas/CameraDragInteractionType" - } - ], - "description": "The type of camera drag interaction." + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment": { + "get": { + "tags": [ + "payments" + ], + "summary": "Get payment info about your user.", + "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It gets the payment information for the authenticated user.", + "operationId": "get_payment_information_for_user", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "sequence": { - "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", - "format": "uint32", - "minimum": 0, - "nullable": true, - "type": "integer" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "camera_drag_move" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The current mouse position." + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "interaction", - "type", - "window" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Customer" + } + } + } }, - { - "description": "Camera drag ended.", - "properties": { - "interaction": { - "allOf": [ - { - "$ref": "#/components/schemas/CameraDragInteractionType" - } - ], - "description": "The type of camera drag interaction." - }, - "type": { - "enum": [ - "camera_drag_end" - ], - "type": "string" - }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The final mouse position." + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "put": { + "tags": [ + "payments" + ], + "summary": "Update payment info for your user.", + "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It updates the payment information for the authenticated user.", + "operationId": "update_payment_information_for_user", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/BillingInfo" } - }, - "required": [ - "interaction", - "type", - "window" - ], - "type": "object" + } }, - { - "description": "Change what the default camera is looking at.", - "properties": { - "center": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "What the camera is looking at. Center of the camera's field of vision" + "required": true + }, + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "default_camera_look_at" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "up": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Which way is \"up\", from the camera's point of view." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "vantage": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Where the camera is positioned" - } - }, - "required": [ - "center", - "type", - "up", - "vantage" - ], - "type": "object" - }, - { - "description": "Adjust zoom of the default camera.", - "properties": { - "magnitude": { - "description": "Move the camera forward along the vector it's looking at, by this magnitudedefaultCameraZoom. Basically, how much should the camera move forward by.", - "format": "float", - "type": "number" - }, - "type": { - "enum": [ - "default_camera_zoom" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "magnitude", - "type" - ], - "type": "object" - }, - { - "description": "Enable sketch mode, where users can sketch 2D geometry. Users choose a plane to sketch on.", - "properties": { - "animated": { - "description": "Should we animate or snap for the camera transition?", - "type": "boolean" - }, - "distance_to_plane": { - "description": "How far to the sketching plane?", - "format": "float", - "type": "number" - }, - "origin": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "What's the origin of the sketching plane?" - }, - "ortho": { - "description": "Should the camera use orthographic projection? In other words, should an object's size in the rendered image stay constant regardless of its distance from the camera.", - "type": "boolean" - }, - "type": { - "enum": [ - "default_camera_enable_sketch_mode" - ], - "type": "string" - }, - "x_axis": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Which 3D axis of the scene should be the X axis of the sketching plane?" - }, - "y_axis": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Which 3D axis of the scene should be the Y axis of the sketching plane?" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Customer" + } } - }, - "required": [ - "animated", - "distance_to_plane", - "origin", - "ortho", - "type", - "x_axis", - "y_axis" - ], - "type": "object" + } }, - { - "description": "Disable sketch mode, from the default camera.", - "properties": { - "type": { - "enum": [ - "default_camera_disable_sketch_mode" - ], - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "post": { + "tags": [ + "payments" + ], + "summary": "Create payment info for your user.", + "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It creates the payment information for the authenticated user.", + "operationId": "create_payment_information_for_user", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/BillingInfo" } - }, - "required": [ - "type" - ], - "type": "object" + } }, - { - "description": "Export the scene to a file.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to be exported. If this is empty, then all entities are exported.", - "items": { - "format": "uuid", + "required": true + }, + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array" + } }, - "format": { - "allOf": [ - { - "$ref": "#/components/schemas/OutputFormat" - } - ], - "description": "The file format to export to." + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of exported objects.\n\nThis is not the same as the export units. Setting export units is part of the format options." + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "export" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "entity_ids", - "format", - "source_unit", - "type" - ], - "type": "object" - }, - { - "description": "What is this entity's parent?", - "properties": { - "entity_id": { - "description": "ID of the entity being queried.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "entity_get_parent_id" - ], - "type": "string" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Customer" + } } - }, - "required": [ - "entity_id", - "type" - ], - "type": "object" + } }, - { - "description": "How many children does the entity have?", - "properties": { - "entity_id": { - "description": "ID of the entity being queried.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "entity_get_num_children" - ], - "type": "string" - } - }, - "required": [ - "entity_id", - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "What is the UUID of this entity's n-th child?", - "properties": { - "child_index": { - "description": "Index into the entity's list of children.", - "format": "uint32", - "minimum": 0, - "type": "integer" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "delete": { + "tags": [ + "payments" + ], + "summary": "Delete payment info for your user.", + "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It deletes the payment information for the authenticated user.", + "operationId": "delete_payment_information_for_user", + "responses": { + "204": { + "description": "successful deletion", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "entity_id": { - "description": "ID of the entity being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "entity_get_child_uuid" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "child_index", - "entity_id", - "type" - ], - "type": "object" + } }, - { - "description": "What are all UUIDs of this entity's children?", - "properties": { - "entity_id": { - "description": "ID of the entity being queried.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "entity_get_all_child_uuids" - ], - "type": "string" - } - }, - "required": [ - "entity_id", - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "Enter edit mode", - "properties": { - "target": { - "description": "The edit target", - "format": "uuid", - "type": "string" + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_payment_information_for_user", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "edit_mode_enter" - ], - "type": "string" - } - }, - "required": [ - "target", - "type" - ], - "type": "object" - }, - { - "description": "Exit edit mode", - "properties": { - "type": { - "enum": [ - "edit_mode_exit" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" - }, - { - "description": "Modifies the selection by simulating a \"mouse click\" at the given x,y window coordinate Returns ID of whatever was selected.", - "properties": { - "selected_at_window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Where in the window was selected" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "selection_type": { - "allOf": [ - { - "$ref": "#/components/schemas/SceneSelectionType" - } - ], - "description": "What entity was selected?" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "select_with_point" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "selected_at_window", - "selection_type", - "type" - ], - "type": "object" + } }, - { - "description": "Clear the selection", - "properties": { - "type": { - "enum": [ - "select_clear" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "Adds one or more entities (by UUID) to the selection.", - "properties": { - "entities": { - "description": "Which entities to select", - "items": { - "format": "uuid", + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/balance": { + "get": { + "tags": [ + "payments" + ], + "summary": "Get balance for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It gets the balance information for the authenticated user.", + "operationId": "get_payment_balance_for_user", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array" + } }, - "type": { - "enum": [ - "select_add" - ], - "type": "string" - } - }, - "required": [ - "entities", - "type" - ], - "type": "object" - }, - { - "description": "Removes one or more entities (by UUID) from the selection.", - "properties": { - "entities": { - "description": "Which entities to unselect", - "items": { - "format": "uuid", + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array" + } }, - "type": { - "enum": [ - "select_remove" - ], - "type": "string" - } - }, - "required": [ - "entities", - "type" - ], - "type": "object" - }, - { - "description": "Replaces the current selection with these new entities (by UUID). Equivalent to doing SelectClear then SelectAdd.", - "properties": { - "entities": { - "description": "Which entities to select", - "items": { - "format": "uuid", + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array" + } }, - "type": { - "enum": [ - "select_replace" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "entities", - "type" - ], - "type": "object" - }, - { - "description": "Find all IDs of selected entities", - "properties": { - "type": { - "enum": [ - "select_get" - ], - "type": "string" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CustomerBalance" + } } - }, - "required": [ - "type" - ], - "type": "object" + } }, - { - "description": "Changes the current highlighted entity to whichever one is at the given window coordinate. If there's no entity at this location, clears the highlight.", - "properties": { - "selected_at_window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Coordinates of the window being clicked" - }, - "sequence": { - "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", - "format": "uint32", - "minimum": 0, - "nullable": true, - "type": "integer" - }, - "type": { - "enum": [ - "highlight_set_entity" - ], - "type": "string" - } - }, - "required": [ - "selected_at_window", - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, - { - "description": "Changes the current highlighted entity to these entities.", - "properties": { - "entities": { - "description": "Highlight these entities.", - "items": { - "format": "uuid", + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/intent": { + "post": { + "tags": [ + "payments", + "hidden" + ], + "summary": "Create a payment intent for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It creates a new payment intent for the authenticated user.", + "operationId": "create_payment_intent_for_user", + "responses": { + "201": { + "description": "successful creation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array" - }, - "type": { - "enum": [ - "highlight_set_entities" - ], - "type": "string" - } - }, - "required": [ - "entities", - "type" - ], - "type": "object" - }, - { - "description": "Create a new annotation", - "properties": { - "annotation_type": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationType" - } - ], - "description": "What type of annotation to create." + } }, - "clobber": { - "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", - "type": "boolean" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "options": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationOptions" - } - ], - "description": "What should the annotation contain?" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "new_annotation" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "annotation_type", - "clobber", - "options", - "type" - ], - "type": "object" - }, - { - "description": "Update an annotation", - "properties": { - "annotation_id": { - "description": "Which annotation to update", - "format": "uuid", - "type": "string" - }, - "options": { - "allOf": [ - { - "$ref": "#/components/schemas/AnnotationOptions" - } - ], - "description": "If any of these fields are set, they will overwrite the previous options for the annotation." - }, - "type": { - "enum": [ - "update_annotation" - ], - "type": "string" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/PaymentIntent" + } } - }, - "required": [ - "annotation_id", - "options", - "type" - ], - "type": "object" + } }, - { - "description": "Hide or show an object", - "properties": { - "hidden": { - "description": "Whether or not the object should be hidden.", - "type": "boolean" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_create_payment_intent_for_user", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object to change", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "object_visible" - ], - "type": "string" - } - }, - "required": [ - "hidden", - "object_id", - "type" - ], - "type": "object" - }, - { - "description": "What type of entity is this?", - "properties": { - "entity_id": { - "description": "ID of the entity being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "get_entity_type" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "entity_id", - "type" - ], - "type": "object" + } }, - { - "description": "Gets all faces which use the given edge.", - "properties": { - "edge_id": { - "description": "Which edge you want the faces of.", - "format": "uuid", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/invoices": { + "get": { + "tags": [ + "payments" + ], + "summary": "List invoices for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It lists invoices for the authenticated user.", + "operationId": "list_invoices_for_user", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object is being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "solid3d_get_all_edge_faces" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "edge_id", - "object_id", - "type" - ], - "type": "object" - }, - { - "description": "Gets all edges which are opposite the given edge, across all possible faces.", - "properties": { - "along_vector": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" + "content": { + "application/json": { + "schema": { + "title": "Array_of_Invoice", + "type": "array", + "items": { + "$ref": "#/components/schemas/Invoice" } - ], - "description": "If given, ohnly faces parallel to this vector will be considered.", - "nullable": true - }, - "edge_id": { - "description": "Which edge you want the opposites of.", - "format": "uuid", - "type": "string" - }, - "object_id": { - "description": "Which object is being queried.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "solid3d_get_all_opposite_edges" - ], - "type": "string" + } } - }, - "required": [ - "edge_id", - "object_id", - "type" - ], - "type": "object" + } }, - { - "description": "Gets the edge opposite the given edge, along the given face.", - "properties": { - "edge_id": { - "description": "Which edge you want the opposite of.", - "format": "uuid", - "type": "string" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/methods": { + "get": { + "tags": [ + "payments" + ], + "summary": "List payment methods for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It lists payment methods for the authenticated user.", + "operationId": "list_payment_methods_for_user", + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "face_id": { - "description": "Which face is used to figure out the opposite edge?", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object is being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "solid3d_get_opposite_edge" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "edge_id", - "face_id", - "object_id", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "title": "Array_of_PaymentMethod", + "type": "array", + "items": { + "$ref": "#/components/schemas/PaymentMethod" + } + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/methods/{id}": { + "delete": { + "tags": [ + "payments", + "hidden" + ], + "summary": "Delete a payment method for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It deletes the specified payment method for the authenticated user.", + "operationId": "delete_payment_method_for_user", + "parameters": [ { - "description": "Gets the next adjacent edge for the given edge, along the given face.", - "properties": { - "edge_id": { - "description": "Which edge you want the opposite of.", - "format": "uuid", - "type": "string" + "in": "path", + "name": "id", + "description": "The ID of the payment method.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "successful deletion", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "face_id": { - "description": "Which face is used to figure out the opposite edge?", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object is being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "solid3d_get_next_adjacent_edge" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "edge_id", - "face_id", - "object_id", - "type" - ], - "type": "object" + } }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + }, + "options": { + "tags": [ + "hidden" + ], + "summary": "OPTIONS endpoint.", + "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", + "operationId": "options_payment_methods_for_user", + "parameters": [ { - "description": "Gets the previous adjacent edge for the given edge, along the given face.", - "properties": { - "edge_id": { - "description": "Which edge you want the opposite of.", - "format": "uuid", - "type": "string" + "in": "path", + "name": "id", + "description": "The ID of the payment method.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "face_id": { - "description": "Which face is used to figure out the opposite edge?", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object is being queried.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "solid3d_get_prev_adjacent_edge" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "edge_id", - "face_id", - "object_id", - "type" - ], - "type": "object" + } }, - { - "description": "Sends object to front or back.", - "properties": { - "front": { - "description": "Bring to front = true, send to back = false.", - "type": "boolean" + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/payment/tax": { + "get": { + "tags": [ + "payments", + "hidden" + ], + "summary": "Validate a customer's information is correct and valid for automatic tax.", + "description": "This endpoint requires authentication by any KittyCAD user. It will return an error if the customer's information is not valid for automatic tax. Otherwise, it will return an empty successful response.", + "operationId": "validate_customer_tax_information_for_user", + "responses": { + "204": { + "description": "successful operation, no content", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "object_id": { - "description": "Which object is being changed.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "send_object" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } - }, - "required": [ - "front", - "object_id", - "type" - ], - "type": "object" + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/user/session/{token}": { + "get": { + "tags": [ + "users" + ], + "summary": "Get a session for your user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API token for the user.", + "operationId": "get_session_for_user", + "parameters": [ { - "description": "Set opacity of the entity.", - "properties": { - "entity_id": { - "description": "Which entity is being changed.", - "format": "uuid", - "type": "string" + "in": "path", + "name": "token", + "description": "The API token.", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "opacity": { - "description": "How transparent should it be? 0 or lower is totally transparent. 1 or greater is totally opaque.", - "format": "float", - "type": "number" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "entity_set_opacity" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } + }, + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "entity_id", - "opacity", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Session" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/users": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "List users.", + "description": "This endpoint required authentication by a KittyCAD employee. The users are returned in order of creation, with the most recently created users first.", + "operationId": "list_users", + "parameters": [ + { + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, { - "description": "Fade the entity in or out.", - "properties": { - "duration_seconds": { - "default": 0.4000000059604645, - "description": "How many seconds the animation should take.", - "format": "float", - "type": "number" + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } + }, + { + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "entity_id": { - "description": "Which entity is being changed.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "fade_in": { - "description": "Fade in = true, fade out = false.", - "type": "boolean" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "entity_fade" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "entity_id", - "fade_in", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UserResultsPage" + } + } + } }, - { - "description": "Make a plane.", - "properties": { - "clobber": { - "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", - "type": "boolean" - }, - "origin": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "Origin of the plane" - }, - "size": { - "description": "What should the plane's span/extent? When rendered visually, this is both the width and height along X and Y axis respectively.", - "format": "double", - "type": "number" - }, - "type": { - "enum": [ - "make_plane" - ], - "type": "string" - }, - "x_axis": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "What should the plane's X axis be?" - }, - "y_axis": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" - } - ], - "description": "What should the plane's Y axis be?" - } - }, - "required": [ - "clobber", - "origin", - "size", - "type", - "x_axis", - "y_axis" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + }, + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/users-extended": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "List users with extended information.", + "description": "This endpoint required authentication by a KittyCAD employee. The users are returned in order of creation, with the most recently created users first.", + "operationId": "list_users_extended", + "parameters": [ { - "description": "Set the plane's color.", - "properties": { - "color": { - "allOf": [ - { - "$ref": "#/components/schemas/Color" - } - ], - "description": "What color it should be." - }, - "plane_id": { - "description": "Which plane is being changed.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "plane_set_color" - ], - "type": "string" - } - }, - "required": [ - "color", - "plane_id", - "type" - ], - "type": "object" + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, { - "description": "Set the active tool.", - "properties": { - "tool": { - "allOf": [ - { - "$ref": "#/components/schemas/SceneToolType" - } - ], - "description": "What tool should be active." - }, - "type": { - "enum": [ - "set_tool" - ], - "type": "string" - } - }, - "required": [ - "tool", - "type" - ], - "type": "object" + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, { - "description": "Send a mouse move event.", - "properties": { - "sequence": { - "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", - "format": "uint32", - "minimum": 0, - "nullable": true, - "type": "integer" + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "mouse_move" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Where the mouse is" - } - }, - "required": [ - "type", - "window" - ], - "type": "object" - }, - { - "description": "Send a mouse click event. Updates modified/selected entities.", - "properties": { - "type": { - "enum": [ - "mouse_click" - ], - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Where the mouse is" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "type", - "window" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ExtendedUserResultsPage" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + }, + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/users-extended/{id}": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "Get extended information about a user.", + "description": "To get information about yourself, use `/users-extended/me` as the endpoint. By doing so you will get the user information for the authenticated user.\nAlternatively, to get information about the authenticated user, use `/user/extended` endpoint.\nTo get information about any KittyCAD user, you must be a KittyCAD employee.", + "operationId": "get_user_extended", + "parameters": [ { - "description": "Enable sketch mode on the given plane.", - "properties": { - "animated": { - "description": "Animate the transition to sketch mode.", - "type": "boolean" + "in": "path", + "name": "id", + "description": "The user ID.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "ortho": { - "description": "Use an orthographic camera.", - "type": "boolean" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "plane_id": { - "description": "Sketch on this plane.", - "format": "uuid", - "type": "string" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "sketch_mode_enable" - ], - "type": "string" - } - }, - "required": [ - "animated", - "ortho", - "plane_id", - "type" - ], - "type": "object" - }, - { - "description": "Disable sketch mode.", - "properties": { - "type": { - "enum": [ - "sketch_mode_disable" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "type" - ], - "type": "object" - }, - { - "description": "Get type of a given curve.", - "properties": { - "curve_id": { - "description": "Which curve to query.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "curve_get_type" - ], - "type": "string" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ExtendedUser" + } } - }, - "required": [ - "curve_id", - "type" - ], - "type": "object" + } }, - { - "description": "Get control points of a given curve.", - "properties": { - "curve_id": { - "description": "Which curve to query.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "curve_get_control_points" - ], - "type": "string" - } - }, - "required": [ - "curve_id", - "type" - ], - "type": "object" + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/users/{id}": { + "get": { + "tags": [ + "users", + "hidden" + ], + "summary": "Get a user.", + "description": "To get information about yourself, use `/users/me` as the endpoint. By doing so you will get the user information for the authenticated user.\nAlternatively, to get information about the authenticated user, use `/user` endpoint.\nTo get information about any KittyCAD user, you must be a KittyCAD employee.", + "operationId": "get_user", + "parameters": [ { - "description": "Take a snapshot.", - "properties": { - "format": { - "allOf": [ - { - "$ref": "#/components/schemas/ImageFormat" - } - ], - "description": "What image format to return." + "in": "path", + "name": "id", + "description": "The user ID.", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "take_snapshot" - ], - "type": "string" - } - }, - "required": [ - "format", - "type" - ], - "type": "object" - }, - { - "description": "Add a gizmo showing the axes.", - "properties": { - "clobber": { - "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", - "type": "boolean" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "gizmo_mode": { - "description": "If true, axes gizmo will be placed in the corner of the screen. If false, it will be placed at the origin of the scene.", - "type": "boolean" + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "type": { - "enum": [ - "make_axes_gizmo" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "clobber", - "gizmo_mode", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/User" + } + } + } + }, + "4XX": { + "$ref": "#/components/responses/Error" }, + "5XX": { + "$ref": "#/components/responses/Error" + } + } + } + }, + "/users/{id}/api-calls": { + "get": { + "tags": [ + "api-calls", + "hidden" + ], + "summary": "List API calls for a user.", + "description": "This endpoint requires authentication by any KittyCAD user. It returns the API calls for the authenticated user if \"me\" is passed as the user id.\nAlternatively, you can use the `/user/api-calls` endpoint to get the API calls for your user.\nIf the authenticated user is a KittyCAD employee, then the API calls are returned for the user specified by the user id.\nThe API calls are returned in order of creation, with the most recently created API calls first.", + "operationId": "list_api_calls_for_user", + "parameters": [ { - "description": "Query the given path", - "properties": { - "path_id": { - "description": "Which path to query", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "path_get_info" - ], - "type": "string" - } - }, - "required": [ - "path_id", - "type" - ], - "type": "object" + "in": "path", + "name": "id", + "description": "The user ID.", + "required": true, + "schema": { + "type": "string" + } }, { - "description": "Get curves for vertices within a path", - "properties": { - "path_id": { - "description": "Which path to query", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "path_get_curve_uuids_for_vertices" - ], - "type": "string" - }, - "vertex_ids": { - "description": "IDs of the vertices for which to obtain curve ids from", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "path_id", - "type", - "vertex_ids" - ], - "type": "object" + "in": "query", + "name": "limit", + "description": "Maximum number of items returned by a single call", + "schema": { + "nullable": true, + "type": "integer", + "format": "uint32", + "minimum": 1 + } }, { - "description": "Start dragging mouse.", - "properties": { - "type": { - "enum": [ - "handle_mouse_drag_start" - ], - "type": "string" - }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The mouse position." - } - }, - "required": [ - "type", - "window" - ], - "type": "object" + "in": "query", + "name": "page_token", + "description": "Token returned by previous call to retrieve the subsequent page", + "schema": { + "nullable": true, + "type": "string" + } }, { - "description": "Continue dragging mouse.", - "properties": { - "sequence": { - "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", - "format": "uint32", - "minimum": 0, - "nullable": true, - "type": "integer" - }, - "type": { - "enum": [ - "handle_mouse_drag_move" - ], - "type": "string" + "in": "query", + "name": "sort_by", + "schema": { + "$ref": "#/components/schemas/CreatedAtSortMode" + } + } + ], + "responses": { + "200": { + "description": "successful operation", + "headers": { + "Access-Control-Allow-Credentials": { + "description": "Access-Control-Allow-Credentials header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The mouse position." - } - }, - "required": [ - "type", - "window" - ], - "type": "object" - }, - { - "description": "Stop dragging mouse.", - "properties": { - "type": { - "enum": [ - "handle_mouse_drag_end" - ], - "type": "string" + "Access-Control-Allow-Headers": { + "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "The mouse position." - } - }, - "required": [ - "type", - "window" - ], - "type": "object" - }, - { - "description": "Remove scene objects.", - "properties": { - "object_ids": { - "description": "Objects to remove.", - "items": { - "format": "uuid", + "Access-Control-Allow-Methods": { + "description": "Access-Control-Allow-Methods header.", + "style": "simple", + "required": true, + "schema": { "type": "string" - }, - "type": "array", - "uniqueItems": true + } }, - "type": { - "enum": [ - "remove_scene_objects" - ], - "type": "string" + "Access-Control-Allow-Origin": { + "description": "Access-Control-Allow-Origin header.", + "style": "simple", + "required": true, + "schema": { + "type": "string" + } } }, - "required": [ - "object_ids", - "type" - ], - "type": "object" + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" + } + } + } }, - { - "description": "Utility method. Performs both a ray cast and projection to plane-local coordinates. Returns the plane coordinates for the given window coordinates.", - "properties": { - "plane_id": { - "description": "The plane you're intersecting against.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "plane_intersect_and_project" - ], - "type": "string" - }, - "window": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Window coordinates where the ray cast should be aimed." + "4XX": { + "$ref": "#/components/responses/Error" + }, + "5XX": { + "$ref": "#/components/responses/Error" + } + }, + "x-dropshot-pagination": { + "required": [] + } + } + }, + "/ws/executor/term": { + "get": { + "tags": [ + "executor", + "hidden" + ], + "summary": "Create a terminal.", + "description": "Attach to a docker container to create an interactive terminal.", + "operationId": "create_executor_term", + "responses": { + "default": { + "description": "", + "content": { + "*/*": { + "schema": {} } - }, - "required": [ - "plane_id", - "type", - "window" - ], - "type": "object" + } + } + }, + "x-dropshot-websocket": {} + } + }, + "/ws/modeling/commands": { + "get": { + "tags": [ + "modeling", + "beta" + ], + "summary": "Open a websocket which accepts modeling commands.", + "description": "Pass those commands to the engine via websocket, and pass responses back to the client. Basically, this is a websocket proxy between the frontend/client and the engine.", + "operationId": "modeling_commands_ws", + "parameters": [ + { + "in": "query", + "name": "fps", + "description": "Frames per second of the video feed.", + "schema": { + "type": "integer", + "format": "uint32", + "minimum": 0 + } }, { - "description": "Find the start and end of a curve.", - "properties": { - "curve_id": { - "description": "ID of the curve being queried.", - "format": "uuid", - "type": "string" - }, - "type": { - "enum": [ - "curve_get_end_points" - ], - "type": "string" - } - }, - "required": [ - "curve_id", - "type" - ], - "type": "object" + "in": "query", + "name": "unlocked_framerate", + "description": "If true, engine will render video frames as fast as it can.", + "schema": { + "type": "boolean" + } }, { - "description": "Reconfigure the stream.", - "properties": { - "fps": { - "description": "Frames per second.", - "format": "uint32", - "minimum": 0, - "type": "integer" - }, - "height": { - "description": "Height of the stream.", - "format": "uint32", - "minimum": 0, - "type": "integer" - }, - "type": { - "enum": [ - "reconfigure_stream" - ], - "type": "string" - }, - "width": { - "description": "Width of the stream.", - "format": "uint32", - "minimum": 0, - "type": "integer" - } - }, - "required": [ - "fps", - "height", - "type", - "width" - ], - "type": "object" + "in": "query", + "name": "video_res_height", + "description": "Height of the video feed. Must be a multiple of 4.", + "schema": { + "type": "integer", + "format": "uint32", + "minimum": 0 + } }, { - "description": "Import files to the current model.", - "properties": { - "files": { - "description": "Files to import", - "items": { - "$ref": "#/components/schemas/ImportFile" - }, - "type": "array" - }, - "type": { - "enum": [ - "import_files" - ], - "type": "string" - } - }, - "required": [ - "files", - "type" - ], - "type": "object" + "in": "query", + "name": "video_res_width", + "description": "Width of the video feed. Must be a multiple of 4.", + "schema": { + "type": "integer", + "format": "uint32", + "minimum": 0 + } }, { - "description": "Get the mass of entities in the scene or the default scene.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to get the mass of. If this is empty, then the default scene is included in the mass.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "material_density": { - "description": "The material density.", - "format": "double", - "type": "number" - }, - "material_density_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The material density unit." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The output unit for the mass." - }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of distances in the scene." - }, - "type": { - "enum": [ - "mass" - ], - "type": "string" - } - }, - "required": [ - "entity_ids", - "material_density", - "material_density_unit", - "output_unit", - "source_unit", - "type" - ], - "type": "object" - }, - { - "description": "Get the density of entities in the scene or the default scene.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to get the density of. If this is empty, then the default scene is included in the density.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "material_mass": { - "description": "The material mass.", - "format": "double", - "type": "number" - }, - "material_mass_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The material mass unit." - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitDensity" - } - ], - "description": "The output unit for the density." - }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of distances in the scene." - }, - "type": { - "enum": [ - "density" - ], - "type": "string" + "in": "query", + "name": "webrtc", + "description": "If true, will start a webrtc connection.", + "schema": { + "type": "boolean" + } + } + ], + "requestBody": { + "description": "Websocket requests", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WebSocketRequest" } - }, - "required": [ - "entity_ids", - "material_mass", - "material_mass_unit", - "output_unit", - "source_unit", - "type" - ], - "type": "object" + } }, - { - "description": "Get the volume of entities in the scene or the default scene.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to get the volume of. If this is empty, then the default scene is included in the volume.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitVolume" - } - ], - "description": "The output unit for the volume." - }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of distances in the scene." - }, - "type": { - "enum": [ - "volume" - ], - "type": "string" + "required": true + }, + "responses": { + "default": { + "description": "Websocket responses", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WebSocketResponse" + } } - }, - "required": [ - "entity_ids", - "output_unit", - "source_unit", - "type" - ], - "type": "object" - }, + } + } + }, + "x-dropshot-websocket": {} + } + } + }, + "components": { + "responses": { + "Error": { + "description": "Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Error" + } + } + } + } + }, + "schemas": { + "AccountProvider": { + "description": "An account provider.", + "oneOf": [ { - "description": "Get the center of mass of entities in the scene or the default scene.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to get the center of mass of. If this is empty, then the default scene is included in the center of mass.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The output unit for the center of mass." - }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of distances in the scene." - }, - "type": { - "enum": [ - "center_of_mass" - ], - "type": "string" - } - }, - "required": [ - "entity_ids", - "output_unit", - "source_unit", - "type" - ], - "type": "object" + "description": "The Google account provider.", + "type": "string", + "enum": [ + "google" + ] }, { - "description": "Get the surface area of entities in the scene or the default scene.", - "properties": { - "entity_ids": { - "description": "IDs of the entities to get the surface area of. If this is empty, then the default scene is included in the surface area.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitArea" - } - ], - "description": "The output unit for the surface area." - }, - "source_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "Select the unit interpretation of distances in the scene." - }, - "type": { - "enum": [ - "surface_area" - ], - "type": "string" - } - }, - "required": [ - "entity_ids", - "output_unit", - "source_unit", - "type" - ], - "type": "object" + "description": "The GitHub account provider.", + "type": "string", + "enum": [ + "github" + ] } ] }, - "ModelingCmdId": { - "description": "All commands have unique IDs. These should be randomly generated.", - "format": "uuid", - "type": "string" - }, - "MouseClick": { - "description": "The response from the `MouseClick` command.", - "properties": { - "entities_modified": { - "description": "Entities that are modified.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - }, - "entities_selected": { - "description": "Entities that are selected.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "entities_modified", - "entities_selected" - ], - "type": "object" - }, - "NewAddress": { - "description": "The struct that is used to create a new record. This is automatically generated and has all the same fields as the main struct only it is missing the `id`.", + "AiPluginApi": { + "description": "AI plugin api information.", + "type": "object", "properties": { - "city": { - "description": "The city component.", - "type": "string" + "is_user_authenticated": { + "description": "If the API is authenticated.", + "default": false, + "type": "boolean" }, - "country": { + "type": { + "description": "The type of API.", + "default": "openapi", "allOf": [ { - "$ref": "#/components/schemas/CountryCode" + "$ref": "#/components/schemas/AiPluginApiType" } - ], - "description": "The country component. This is a two-letter ISO country code." - }, - "state": { - "description": "The state component.", - "type": "string" + ] }, - "street1": { - "description": "The first street component.", - "type": "string" - }, - "street2": { - "description": "The second street component.", - "type": "string" - }, - "user_id": { - "description": "The user ID that this address belongs to.", - "type": "string" - }, - "zip": { - "description": "The zip component.", - "type": "string" + "url": { + "description": "The url to the API's schema.", + "type": "string", + "format": "uri" } }, "required": [ - "country" - ], - "type": "object" + "url" + ] }, - "OAuth2ClientInfo": { - "description": "Information about an OAuth 2.0 client.", + "AiPluginApiType": { + "description": "AI plugin api type.", + "oneOf": [ + { + "description": "An OpenAPI specification.", + "type": "string", + "enum": [ + "openapi" + ] + } + ] + }, + "AiPluginAuth": { + "description": "AI plugin auth information.", + "type": "object", "properties": { - "csrf_token": { - "description": "Value used for [CSRF](https://tools.ietf.org/html/rfc6749#section-10.12) protection via the `state` parameter.", - "type": "string" - }, - "pkce_code_verifier": { - "description": "Code Verifier used for [PKCE]((https://tools.ietf.org/html/rfc7636)) protection via the `code_verifier` parameter. The value must have a minimum length of 43 characters and a maximum length of 128 characters. Each character must be ASCII alphanumeric or one of the characters \"-\" / \".\" / \"_\" / \"~\".", + "authorization_type": { "nullable": true, - "type": "string" + "description": "The type of http authorization.", + "allOf": [ + { + "$ref": "#/components/schemas/AiPluginHttpAuthType" + } + ] }, - "url": { - "description": "The URL for consent.", - "type": "string" + "type": { + "description": "The type of authentication.", + "default": "none", + "allOf": [ + { + "$ref": "#/components/schemas/AiPluginAuthType" + } + ] } - }, - "type": "object" + } }, - "OAuth2GrantType": { - "description": "An OAuth 2.0 Grant Type. These are documented here: .", + "AiPluginAuthType": { + "description": "AI plugin auth type.", "oneOf": [ { - "description": "An OAuth 2.0 Device Authorization Grant.", + "description": "None.", + "type": "string", "enum": [ - "urn:ietf:params:oauth:grant-type:device_code" - ], - "type": "string" + "none" + ] + }, + { + "description": "User http.", + "type": "string", + "enum": [ + "user_http" + ] + }, + { + "description": "Service http.", + "type": "string", + "enum": [ + "service_http" + ] + }, + { + "description": "OAuth.", + "type": "string", + "enum": [ + "oauth" + ] } ] }, - "OkModelingCmdResponse": { - "description": "A successful response from a modeling command. This can be one of several types of responses, depending on the command.", + "AiPluginHttpAuthType": { + "description": "AI plugin http auth type.", "oneOf": [ { - "description": "An empty response, used for any command that does not explicitly have a response defined here.", - "properties": { - "type": { - "enum": [ - "empty" - ], - "type": "string" - } - }, - "required": [ - "type" - ], - "type": "object" + "description": "Basic.", + "type": "string", + "enum": [ + "basic" + ] }, { - "description": "The response from the `Export` command. When this is being performed over a websocket, this is sent as binary not JSON. The binary data can be deserialized as `bincode` into a `Vec`.", - "properties": { - "data": { - "$ref": "#/components/schemas/Export" - }, - "type": { - "enum": [ - "export" - ], - "type": "string" + "description": "Bearer.", + "type": "string", + "enum": [ + "bearer" + ] + } + ] + }, + "AiPluginManifest": { + "description": "AI plugin manifest.\n\nThis is used for OpenAI's ChatGPT plugins. You can read more about them [here](https://platform.openai.com/docs/plugins/getting-started/plugin-manifest).", + "type": "object", + "properties": { + "api": { + "description": "API specification.", + "allOf": [ + { + "$ref": "#/components/schemas/AiPluginApi" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `SelectWithPoint` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/SelectWithPoint" - }, - "type": { - "enum": [ - "select_with_point" - ], - "type": "string" + "auth": { + "description": "Authentication schema.", + "allOf": [ + { + "$ref": "#/components/schemas/AiPluginAuth" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `HighlightSetEntity` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/HighlightSetEntity" - }, - "type": { - "enum": [ - "highlight_set_entity" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "contact_email": { + "description": "Email contact for safety/moderation reachout, support, and deactivation.", + "type": "string", + "format": "email" }, - { - "description": "The response from the `EntityGetChildUuid` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/EntityGetChildUuid" - }, - "type": { - "enum": [ - "entity_get_child_uuid" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description_for_human": { + "description": "Human-readable description of the plugin.", + "type": "string" }, - { - "description": "The response from the `EntityGetNumChildren` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/EntityGetNumChildren" - }, - "type": { - "enum": [ - "entity_get_num_children" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description_for_model": { + "description": "Description better tailored to the model, such as token context length considerations or keyword usage for improved plugin prompting.", + "type": "string" }, - { - "description": "The response from the `EntityGetParentId` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/EntityGetParentId" - }, - "type": { - "enum": [ - "entity_get_parent_id" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "legal_info_url": { + "description": "Redirect URL for users to view plugin information.", + "type": "string", + "format": "uri" }, - { - "description": "The response from the `EntityGetAllChildUuids` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/EntityGetAllChildUuids" - }, - "type": { - "enum": [ - "entity_get_all_child_uuids" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "logo_url": { + "description": "URL used to fetch the plugin's logo.", + "type": "string", + "format": "uri" }, - { - "description": "The response from the `SelectGet` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/SelectGet" - }, - "type": { - "enum": [ - "select_get" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "name_for_human": { + "description": "Human-readable name, such as the full company name.", + "type": "string" }, - { - "description": "The response from the `GetEntityType` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/GetEntityType" - }, - "type": { - "enum": [ - "get_entity_type" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "name_for_model": { + "description": "Name the model will used to target the plugin.", + "type": "string" }, - { - "description": "The response from the `Solid3dGetAllEdgeFaces` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Solid3dGetAllEdgeFaces" - }, - "type": { - "enum": [ - "solid3d_get_all_edge_faces" - ], - "type": "string" + "schema_version": { + "description": "Manifest schema version.", + "type": "string" + } + }, + "required": [ + "api", + "auth", + "legal_info_url", + "logo_url" + ] + }, + "Angle": { + "description": "An angle, with a specific unit.", + "type": "object", + "properties": { + "unit": { + "description": "What unit is the measurement?", + "allOf": [ + { + "$ref": "#/components/schemas/UnitAngle" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `Solid3dGetAllOppositeEdges` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Solid3dGetAllOppositeEdges" - }, - "type": { - "enum": [ - "solid3d_get_all_opposite_edges" - ], - "type": "string" + "value": { + "description": "The size of the angle, measured in the chosen unit.", + "type": "number", + "format": "double" + } + }, + "required": [ + "unit", + "value" + ] + }, + "AnnotationLineEnd": { + "description": "Annotation line end type", + "type": "string", + "enum": [ + "none", + "arrow" + ] + }, + "AnnotationLineEndOptions": { + "description": "Options for annotation text", + "type": "object", + "properties": { + "end": { + "description": "How to style the end of the annotation line.", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationLineEnd" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `Solid3dGetOppositeEdge` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Solid3dGetOppositeEdge" - }, - "type": { - "enum": [ - "solid3d_get_opposite_edge" - ], - "type": "string" + "start": { + "description": "How to style the start of the annotation line.", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationLineEnd" } - }, - "required": [ - "data", - "type" - ], - "type": "object" - }, - { - "description": "The response from the `Solid3dGetPrevAdjacentEdge` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Solid3dGetPrevAdjacentEdge" - }, - "type": { - "enum": [ - "solid3d_get_prev_adjacent_edge" - ], - "type": "string" + ] + } + }, + "required": [ + "end", + "start" + ] + }, + "AnnotationOptions": { + "description": "Options for annotations", + "type": "object", + "properties": { + "color": { + "nullable": true, + "description": "Color to render the annotation", + "allOf": [ + { + "$ref": "#/components/schemas/Color" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `Solid3dGetNextAdjacentEdge` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Solid3dGetNextAdjacentEdge" - }, - "type": { - "enum": [ - "solid3d_get_next_adjacent_edge" - ], - "type": "string" + "line_ends": { + "nullable": true, + "description": "How to style the start and end of the line", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationLineEndOptions" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `MouseClick` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/MouseClick" - }, - "type": { - "enum": [ - "mouse_click" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "line_width": { + "nullable": true, + "description": "Width of the annotation's line", + "type": "number", + "format": "float" }, - { - "description": "The response from the `CurveGetType` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/CurveGetType" - }, - "type": { - "enum": [ - "curve_get_type" - ], - "type": "string" + "position": { + "nullable": true, + "description": "Position to put the annotation", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `CurveGetControlPoints` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/CurveGetControlPoints" - }, - "type": { - "enum": [ - "curve_get_control_points" - ], - "type": "string" + "text": { + "nullable": true, + "description": "Text displayed on the annotation", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationTextOptions" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] + } + } + }, + "AnnotationTextAlignmentX": { + "description": "Horizontal Text aligment", + "type": "string", + "enum": [ + "left", + "center", + "right" + ] + }, + "AnnotationTextAlignmentY": { + "description": "Vertical Text aligment", + "type": "string", + "enum": [ + "bottom", + "center", + "top" + ] + }, + "AnnotationTextOptions": { + "description": "Options for annotation text", + "type": "object", + "properties": { + "point_size": { + "description": "Text font's point size", + "type": "integer", + "format": "uint32", + "minimum": 0 }, - { - "description": "The response from the `Take Snapshot` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/TakeSnapshot" - }, - "type": { - "enum": [ - "take_snapshot" - ], - "type": "string" + "text": { + "description": "Text displayed on the annotation", + "type": "string" + }, + "x": { + "description": "Alignment along the X axis", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationTextAlignmentX" } - }, - "required": [ - "data", - "type" - ], - "type": "object" + ] }, - { - "description": "The response from the `Path Get Info` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/PathGetInfo" - }, - "type": { - "enum": [ - "path_get_info" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" - }, - { - "description": "The response from the `Path Get Curve UUIDs for Vertices` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/PathGetCurveUuidsForVertices" - }, - "type": { - "enum": [ - "path_get_curve_uuids_for_vertices" - ], - "type": "string" + "y": { + "description": "Alignment along the Y axis", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationTextAlignmentY" } - }, - "required": [ - "data", - "type" - ], - "type": "object" - }, + ] + } + }, + "required": [ + "point_size", + "text", + "x", + "y" + ] + }, + "AnnotationType": { + "description": "The type of annotation", + "oneOf": [ { - "description": "The response from the `PlaneIntersectAndProject` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/PlaneIntersectAndProject" - }, - "type": { - "enum": [ - "plane_intersect_and_project" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "2D annotation type (screen or planar space)", + "type": "string", + "enum": [ + "t2d" + ] }, { - "description": "The response from the `CurveGetEndPoints` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/CurveGetEndPoints" - }, - "type": { - "enum": [ - "curve_get_end_points" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "3D annotation type", + "type": "string", + "enum": [ + "t3d" + ] + } + ] + }, + "ApiCallQueryGroup": { + "description": "A response for a query on the API call table that is grouped by something.", + "type": "object", + "properties": { + "count": { + "type": "integer", + "format": "int64" }, + "query": { + "type": "string" + } + }, + "required": [ + "count", + "query" + ] + }, + "ApiCallQueryGroupBy": { + "description": "The field of an API call to group by.", + "oneOf": [ { - "description": "The response from the `ImportFiles` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/ImportFiles" - }, - "type": { - "enum": [ - "import_files" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The email of the user that requested the API call.", + "type": "string", + "enum": [ + "email" + ] }, { - "description": "The response from the `Mass` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Mass" - }, - "type": { - "enum": [ - "mass" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The HTTP method of the API call.", + "type": "string", + "enum": [ + "method" + ] }, { - "description": "The response from the `Volume` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Volume" - }, - "type": { - "enum": [ - "volume" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The endpoint of the API call.", + "type": "string", + "enum": [ + "endpoint" + ] }, { - "description": "The response from the `Density` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/Density" - }, - "type": { - "enum": [ - "density" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The user ID of the user that requested the API call.", + "type": "string", + "enum": [ + "user_id" + ] }, { - "description": "The response from the `SurfaceArea` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/SurfaceArea" - }, - "type": { - "enum": [ - "surface_area" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The origin of the API call. This is parsed from the `Origin` header.", + "type": "string", + "enum": [ + "origin" + ] }, { - "description": "The response from the `CenterOfMass` command.", - "properties": { - "data": { - "$ref": "#/components/schemas/CenterOfMass" - }, - "type": { - "enum": [ - "center_of_mass" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The IP address of the user making the API call.", + "type": "string", + "enum": [ + "ip_address" + ] } ] }, - "OkWebSocketResponseData": { - "description": "The websocket messages this server sends.", + "ApiCallStatus": { + "description": "The status of an async API call.", "oneOf": [ { - "description": "Information about the ICE servers.", - "properties": { - "data": { - "properties": { - "ice_servers": { - "description": "Information about the ICE servers.", - "items": { - "$ref": "#/components/schemas/IceServer" - }, - "type": "array" - } - }, - "required": [ - "ice_servers" - ], - "type": "object" - }, - "type": { - "enum": [ - "ice_server_info" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" - }, - { - "description": "The trickle ICE candidate response.", - "properties": { - "data": { - "properties": { - "candidate": { - "allOf": [ - { - "$ref": "#/components/schemas/RtcIceCandidateInit" - } - ], - "description": "Information about the ICE candidate." - } - }, - "required": [ - "candidate" - ], - "type": "object" - }, - "type": { - "enum": [ - "trickle_ice" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The async API call is queued.", + "type": "string", + "enum": [ + "queued" + ] }, { - "description": "The SDP answer response.", - "properties": { - "data": { - "properties": { - "answer": { - "allOf": [ - { - "$ref": "#/components/schemas/RtcSessionDescription" - } - ], - "description": "The session description." - } - }, - "required": [ - "answer" - ], - "type": "object" - }, - "type": { - "enum": [ - "sdp_answer" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The async API call was uploaded to be converted.", + "type": "string", + "enum": [ + "uploaded" + ] }, { - "description": "The modeling command response.", - "properties": { - "data": { - "properties": { - "modeling_response": { - "allOf": [ - { - "$ref": "#/components/schemas/OkModelingCmdResponse" - } - ], - "description": "The result of the command." - } - }, - "required": [ - "modeling_response" - ], - "type": "object" - }, - "type": { - "enum": [ - "modeling" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The async API call is in progress.", + "type": "string", + "enum": [ + "in_progress" + ] }, { - "description": "The exported files.", - "properties": { - "data": { - "properties": { - "files": { - "description": "The exported files", - "items": { - "$ref": "#/components/schemas/RawFile" - }, - "type": "array" - } - }, - "required": [ - "files" - ], - "type": "object" - }, - "type": { - "enum": [ - "export" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The async API call has completed.", + "type": "string", + "enum": [ + "completed" + ] }, { - "description": "Request a collection of metrics, to include WebRTC.", - "properties": { - "data": { - "type": "object" - }, - "type": { - "enum": [ - "metrics_request" - ], - "type": "string" - } - }, - "required": [ - "data", - "type" - ], - "type": "object" + "description": "The async API call has failed.", + "type": "string", + "enum": [ + "failed" + ] } ] }, - "Onboarding": { - "description": "Onboarding details", + "ApiCallWithPrice": { + "description": "An API call with the price.\n\nThis is a join of the `ApiCall` and `ApiCallPrice` tables.", + "type": "object", "properties": { - "first_call_from_their_machine_date": { - "description": "When the user first called an endpoint from their machine (i.e. not a litterbox execution)", + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The date and time the API call completed billing.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The date and time the API call was created.", + "type": "string", + "format": "date-time" + }, + "duration": { + "nullable": true, + "title": "int64", + "description": "The duration of the API call.", + "type": "integer", + "format": "duration" + }, + "email": { + "description": "The user's email address.", + "type": "string", + "format": "email" + }, + "endpoint": { + "description": "The endpoint requested by the API call.", "type": "string" }, - "first_litterbox_execute_date": { - "description": "When the user first used the litterbox", + "id": { + "description": "The unique identifier for the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "ip_address": { + "title": "String", + "description": "The ip address of the origin.", + "default": "", + "type": "string", + "format": "ip" + }, + "litterbox": { + "nullable": true, + "description": "If the API call was spawned from the litterbox or not.", + "type": "boolean" + }, + "method": { + "description": "The HTTP method requsted by the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/Method" + } + ] + }, + "minutes": { + "nullable": true, + "description": "The number of minutes the API call was billed for.", + "type": "integer", + "format": "int32" + }, + "origin": { + "description": "The origin of the API call.", "type": "string" }, - "first_token_date": { - "description": "When the user created their first token", + "price": { + "nullable": true, + "title": "double", + "description": "The price of the API call.", + "type": "number", + "format": "money-usd" + }, + "request_body": { + "nullable": true, + "description": "The request body sent by the API call.", + "type": "string" + }, + "request_query_params": { + "description": "The request query params sent by the API call.", + "type": "string" + }, + "response_body": { + "nullable": true, + "description": "The response body returned by the API call. We do not store this information if it is above a certain size.", + "type": "string" + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The date and time the API call started billing.", + "type": "string", + "format": "date-time" + }, + "status_code": { + "nullable": true, + "title": "int32", + "description": "The status code returned by the API call.", + "type": "integer", + "format": "int32" + }, + "stripe_invoice_item_id": { + "description": "The Stripe invoice item ID of the API call if it is billable.", + "type": "string" + }, + "token": { + "description": "The API token that made the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The date and time the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_agent": { + "description": "The user agent of the request.", + "type": "string" + }, + "user_id": { + "description": "The ID of the user that made the API call.", "type": "string" } }, - "type": "object" + "required": [ + "created_at", + "id", + "method", + "token", + "updated_at", + "user_agent" + ] }, - "OutputFile": { - "description": "Output file contents.", + "ApiCallWithPriceResultsPage": { + "description": "A single page of results", + "type": "object", "properties": { - "contents": { - "description": "The contents of the file. This is base64 encoded so we can ensure it is UTF-8 for JSON.", + "items": { + "description": "list of items on this page of results", + "type": "array", + "items": { + "$ref": "#/components/schemas/ApiCallWithPrice" + } + }, + "next_page": { "nullable": true, + "description": "token used to fetch the next page of results (if any)", "type": "string" + } + }, + "required": [ + "items" + ] + }, + "ApiError": { + "description": "An error.", + "type": "object", + "properties": { + "error_code": { + "description": "The error code.", + "allOf": [ + { + "$ref": "#/components/schemas/ErrorCode" + } + ] }, - "name": { - "default": "", - "description": "The name of the file.", + "message": { + "description": "The error message.", "type": "string" } }, - "type": "object" + "required": [ + "error_code", + "message" + ] }, - "OutputFormat": { - "description": "Output format specifier.", - "oneOf": [ - { - "description": "Autodesk Filmbox (FBX) format.", - "properties": { - "storage": { - "allOf": [ - { - "$ref": "#/components/schemas/FbxStorage" - } - ], - "description": "Specifies which kind of FBX will be exported." - }, - "type": { - "enum": [ - "fbx" - ], - "type": "string" + "ApiToken": { + "description": "An API token.\n\nThese are used to authenticate users with Bearer authentication.", + "type": "object", + "properties": { + "created_at": { + "title": "DateTime", + "description": "The date and time the API token was created.", + "type": "string", + "format": "date-time" + }, + "id": { + "description": "The unique identifier for the API token.", + "type": "string" + }, + "is_valid": { + "description": "If the token is valid. We never delete API tokens, but we can mark them as invalid. We save them for ever to preserve the history of the API token.", + "type": "boolean" + }, + "token": { + "description": "The API token itself.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "required": [ - "storage", - "type" - ], - "type": "object" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The date and time the API token was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The ID of the user that owns the API token.", + "type": "string" + } + }, + "required": [ + "created_at", + "is_valid", + "token", + "updated_at" + ] + }, + "ApiTokenResultsPage": { + "description": "A single page of results", + "type": "object", + "properties": { + "items": { + "description": "list of items on this page of results", + "type": "array", + "items": { + "$ref": "#/components/schemas/ApiToken" + } + }, + "next_page": { + "nullable": true, + "description": "token used to fetch the next page of results (if any)", + "type": "string" + } + }, + "required": [ + "items" + ] + }, + "AppClientInfo": { + "description": "Information about a third party app client.", + "type": "object", + "properties": { + "url": { + "description": "The URL for consent.", + "type": "string" + } + } + }, + "AsyncApiCall": { + "description": "An async API call.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the async API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the async API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the async API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "input": { + "description": "The JSON input for the API call. These are determined by the endpoint that is run." + }, + "output": { + "nullable": true, + "description": "The JSON output for the API call. These are determined by the endpoint that is run." + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the async API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the async API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "type": { + "description": "The type of async API call.", + "allOf": [ + { + "$ref": "#/components/schemas/AsyncApiCallType" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the async API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the async API call.", + "type": "string" }, + "worker": { + "description": "The worker node that is performing or performed the async API call.", + "type": "string" + } + }, + "required": [ + "created_at", + "id", + "status", + "type", + "updated_at" + ] + }, + "AsyncApiCallOutput": { + "description": "The output from the async API call.", + "oneOf": [ { - "description": "glTF 2.0. We refer to this as glTF since that is how our customers refer to it, although by default it will be in binary format and thus technically (glb). If you prefer ascii output, you can set that option for the export.", + "description": "A file conversion.", + "type": "object", "properties": { - "presentation": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { - "$ref": "#/components/schemas/GltfPresentation" + "$ref": "#/components/schemas/Uuid" } - ], - "description": "Specifies how the JSON will be presented." + ] }, - "storage": { + "output_format": { + "description": "The output format of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/GltfStorage" + "$ref": "#/components/schemas/FileExportFormat" } - ], - "description": "Specifies which kind of glTF 2.0 will be exported." + ] }, - "type": { - "enum": [ - "gltf" - ], - "type": "string" - } - }, - "required": [ - "presentation", - "storage", - "type" - ], - "type": "object" - }, - { - "description": "Wavefront OBJ format.", - "properties": { - "coords": { + "output_format_options": { + "nullable": true, + "description": "The output format options of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/System" + "$ref": "#/components/schemas/OutputFormat" } - ], - "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + ] }, - "type": { - "enum": [ - "obj" - ], - "type": "string" + "outputs": { + "description": "The converted files (if multiple file conversion), if completed, base64 encoded. The key of the map is the path of the output file.", + "type": "object", + "additionalProperties": { + "title": "String", + "type": "string", + "format": "byte" + } }, - "units": { + "src_format": { + "description": "The source format of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/UnitLength" + "$ref": "#/components/schemas/FileImportFormat" } - ], - "description": "Export length unit.\n\nDefaults to meters." - } - }, - "required": [ - "coords", - "type", - "units" - ], - "type": "object" - }, - { - "description": "The PLY Polygon File Format.", - "properties": { - "coords": { + ] + }, + "src_format_options": { + "nullable": true, + "description": "The source format options of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/System" + "$ref": "#/components/schemas/InputFormat" } - ], - "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + ] }, - "storage": { + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", "allOf": [ { - "$ref": "#/components/schemas/PlyStorage" + "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "The storage for the output PLY file." + ] }, "type": { + "type": "string", "enum": [ - "ply" - ], + "file_conversion" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", "type": "string" } }, "required": [ - "coords", - "storage", - "type" - ], - "type": "object" + "created_at", + "id", + "output_format", + "src_format", + "status", + "type", + "updated_at" + ] }, { - "description": "ISO 10303-21 (STEP) format.", + "description": "File center of mass.", + "type": "object", "properties": { - "coords": { + "center_of_mass": { + "nullable": true, + "description": "The resulting center of mass.", "allOf": [ { - "$ref": "#/components/schemas/System" + "$ref": "#/components/schemas/Point3d" } - ], - "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + ] }, - "type": { - "enum": [ - "step" - ], + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", "type": "string" - } - }, - "required": [ - "coords", - "type" - ], - "type": "object" - }, - { - "description": "*ST**ereo**L**ithography format.", - "properties": { - "coords": { + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { - "$ref": "#/components/schemas/System" + "$ref": "#/components/schemas/Uuid" } - ], - "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html" + ] }, - "storage": { + "output_unit": { + "description": "The output unit for the center of mass.", "allOf": [ { - "$ref": "#/components/schemas/StlStorage" + "$ref": "#/components/schemas/UnitLength" } - ], - "description": "Export storage." + ] }, - "type": { - "enum": [ - "stl" - ], - "type": "string" - }, - "units": { + "src_format": { + "description": "The source format of the file.", "allOf": [ { - "$ref": "#/components/schemas/UnitLength" + "$ref": "#/components/schemas/FileImportFormat" } - ], - "description": "Export length unit.\n\nDefaults to meters." - } - }, - "required": [ - "coords", - "storage", - "type", - "units" - ], - "type": "object" - } - ] - }, - "PathCommand": { - "description": "The path component command type (within a Path)", - "enum": [ - "move_to", - "line_to", - "bez_curve_to", - "nurbs_curve_to", - "add_arc" - ], - "type": "string" - }, - "PathGetCurveUuidsForVertices": { - "description": "The response from the `PathGetCurveUuidsForVertices` command.", - "properties": { - "curve_ids": { - "description": "The UUIDs of the curve entities.", - "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "curve_ids" - ], - "type": "object" - }, - "PathGetInfo": { - "description": "The response from the `PathGetInfo` command.", - "properties": { - "segments": { - "description": "All segments in the path, in the order they were added.", - "items": { - "$ref": "#/components/schemas/PathSegmentInfo" - }, - "type": "array" - } - }, - "required": [ - "segments" - ], - "type": "object" - }, - "PathSegment": { - "description": "A segment of a path. Paths are composed of many segments.", - "oneOf": [ - { - "description": "A straight line segment. Goes from the current path \"pen\" to the given endpoint.", - "properties": { - "end": { + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", "allOf": [ { - "$ref": "#/components/schemas/Point3d" + "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "End point of the line." - }, - "relative": { - "description": "Whether or not this line is a relative offset", - "type": "boolean" + ] }, "type": { + "type": "string", "enum": [ - "line" - ], + "file_center_of_mass" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", "type": "string" } }, "required": [ - "end", - "relative", - "type" - ], - "type": "object" + "created_at", + "id", + "output_unit", + "src_format", + "status", + "type", + "updated_at" + ] }, { - "description": "A circular arc segment.", + "description": "A file mass.", + "type": "object", "properties": { - "angle_end": { - "description": "Start of the arc along circle's perimeter.", - "format": "double", - "type": "number" + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, - "angle_start": { - "description": "Start of the arc along circle's perimeter.", - "format": "double", - "type": "number" + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" }, - "center": { + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { - "$ref": "#/components/schemas/Point2d" + "$ref": "#/components/schemas/Uuid" } - ], - "description": "Center of the circle" + ] }, - "radius": { - "description": "Radius of the circle", - "format": "double", - "type": "number" + "mass": { + "nullable": true, + "description": "The resulting mass.", + "type": "number", + "format": "double" }, - "relative": { - "description": "Whether or not this arc is a relative offset", - "type": "boolean" + "material_density": { + "description": "The material density as denoted by the user.", + "default": 0.0, + "type": "number", + "format": "double" }, - "type": { - "enum": [ - "arc" - ], - "type": "string" - } - }, - "required": [ - "angle_end", - "angle_start", - "center", - "radius", - "relative", - "type" - ], - "type": "object" - }, - { - "description": "A cubic bezier curve segment. Start at the end of the current line, go through control point 1 and 2, then end at a given point.", - "properties": { - "control1": { + "material_density_unit": { + "description": "The material density unit.", "allOf": [ { - "$ref": "#/components/schemas/Point3d" + "$ref": "#/components/schemas/UnitDensity" } - ], - "description": "First control point." + ] }, - "control2": { + "output_unit": { + "description": "The output unit for the mass.", "allOf": [ { - "$ref": "#/components/schemas/Point3d" + "$ref": "#/components/schemas/UnitMass" } - ], - "description": "Second control point." + ] }, - "end": { + "src_format": { + "description": "The source format of the file.", "allOf": [ { - "$ref": "#/components/schemas/Point3d" + "$ref": "#/components/schemas/FileImportFormat" } - ], - "description": "Final control point." + ] }, - "relative": { - "description": "Whether or not this bezier is a relative offset", - "type": "boolean" + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, - "type": { - "enum": [ - "bezier" - ], - "type": "string" - } - }, - "required": [ - "control1", - "control2", - "end", - "relative", - "type" - ], - "type": "object" - }, - { - "description": "Adds a tangent arc from current pen position with the given radius and angle.", - "properties": { - "offset": { + "status": { + "description": "The status of the API call.", "allOf": [ { - "$ref": "#/components/schemas/Angle" + "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "Offset of the arc." - }, - "radius": { - "description": "Radius of the arc. Not to be confused with Raiders of the Lost Ark.", - "format": "double", - "type": "number" + ] }, "type": { + "type": "string", "enum": [ - "tangential_arc" - ], + "file_mass" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", "type": "string" } }, "required": [ - "offset", - "radius", - "type" - ], - "type": "object" + "created_at", + "id", + "material_density_unit", + "output_unit", + "src_format", + "status", + "type", + "updated_at" + ] }, { - "description": "Adds a tangent arc from current pen position to the new position.", + "description": "A file volume.", + "type": "object", "properties": { - "angle_snap_increment": { - "allOf": [ - { - "$ref": "#/components/schemas/Angle" - } - ], - "description": "0 will be interpreted as none/null.", - "nullable": true + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, - "to": { - "allOf": [ - { - "$ref": "#/components/schemas/Point3d" + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "output_unit": { + "description": "The output unit for the volume.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" + } + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "Where the arc should end. Must lie in the same plane as the current path pen position. Must not be colinear with current path pen position." + ] }, "type": { + "type": "string", "enum": [ - "tangential_arc_to" - ], + "file_volume" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", "type": "string" + }, + "volume": { + "nullable": true, + "description": "The resulting volume.", + "type": "number", + "format": "double" } }, "required": [ - "to", - "type" - ], - "type": "object" - } - ] - }, - "PathSegmentInfo": { - "description": "Info about a path segment", - "properties": { - "command": { - "allOf": [ - { - "$ref": "#/components/schemas/PathCommand" - } - ], - "description": "What is the path segment?" - }, - "command_id": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmdId" - } - ], - "description": "Which command created this path? This field is absent if the path command is not actually creating a path segment, e.g. moving the pen doesn't create a path segment.", - "nullable": true - }, - "relative": { - "description": "Whether or not this segment is a relative offset", - "type": "boolean" - } - }, - "required": [ - "command", - "relative" - ], - "type": "object" - }, - "PaymentIntent": { - "description": "A payment intent response.", - "properties": { - "client_secret": { - "description": "The client secret is used for client-side retrieval using a publishable key. The client secret can be used to complete payment setup from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.", - "type": "string" - } - }, - "required": [ - "client_secret" - ], - "type": "object" - }, - "PaymentMethod": { - "description": "A payment method.", - "properties": { - "billing_info": { - "allOf": [ - { - "$ref": "#/components/schemas/BillingInfo" - } - ], - "description": "The billing info for the payment method." - }, - "card": { - "allOf": [ - { - "$ref": "#/components/schemas/CardDetails" - } - ], - "description": "The card, if it is one. For our purposes, this is the only type of payment method that we support.", - "nullable": true - }, - "created_at": { - "description": "Time at which the object was created.", - "format": "date-time", - "type": "string" - }, - "id": { - "description": "Unique identifier for the object.", - "type": "string" - }, - "metadata": { - "additionalProperties": { - "type": "string" - }, - "default": {}, - "description": "Set of key-value pairs.", - "type": "object" - }, - "type": { - "allOf": [ - { - "$ref": "#/components/schemas/PaymentMethodType" - } - ], - "description": "The type of payment method." - } - }, - "required": [ - "billing_info", - "created_at", - "type" - ], - "type": "object" - }, - "PaymentMethodCardChecks": { - "description": "Card checks.", - "properties": { - "address_line1_check": { - "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "type": "string" - }, - "address_postal_code_check": { - "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "type": "string" - }, - "cvc_check": { - "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", - "type": "string" - } - }, - "type": "object" - }, - "PaymentMethodType": { - "description": "An enum representing the possible values of an `PaymentMethod`'s `type` field.", - "oneOf": [ - { - "description": "A card payment method.", - "enum": [ - "card" - ], - "type": "string" - } - ] - }, - "PlaneIntersectAndProject": { - "description": "Corresponding coordinates of given window coordinates, intersected on given plane.", - "properties": { - "plane_coordinates": { - "allOf": [ - { - "$ref": "#/components/schemas/Point2d" - } - ], - "description": "Corresponding coordinates of given window coordinates, intersected on given plane.", - "nullable": true - } - }, - "type": "object" - }, - "PlyStorage": { - "description": "The storage for the output PLY file.", - "oneOf": [ - { - "description": "Write numbers in their ascii representation (e.g. -13, 6.28, etc.). Properties are separated by spaces and elements are separated by line breaks.", - "enum": [ - "ascii" - ], - "type": "string" - }, - { - "description": "Encode payload as binary using little endian.", - "enum": [ - "binary_little_endian" - ], - "type": "string" - }, - { - "description": "Encode payload as binary using big endian.", - "enum": [ - "binary_big_endian" - ], - "type": "string" - } - ] - }, - "Point2d": { - "description": "A point in 2D space", - "properties": { - "x": { - "format": "double", - "type": "number" - }, - "y": { - "format": "double", - "type": "number" - } - }, - "required": [ - "x", - "y" - ], - "type": "object" - }, - "Point3d": { - "description": "A point in 3D space", - "properties": { - "x": { - "format": "float", - "type": "number" - }, - "y": { - "format": "float", - "type": "number" - }, - "z": { - "format": "float", - "type": "number" - } - }, - "required": [ - "x", - "y", - "z" - ], - "type": "object" - }, - "PointEMetadata": { - "description": "Metadata about our point-e instance.\n\nThis is mostly used for internal purposes and debugging.", - "properties": { - "ok": { - "description": "If the point-e service returned an ok response from ping.", - "type": "boolean" - } - }, - "required": [ - "ok" - ], - "type": "object" - }, - "Pong": { - "description": "The response from the `/ping` endpoint.", - "properties": { - "message": { - "description": "The pong response.", - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - }, - "RawFile": { - "description": "A raw file with unencoded contents to be passed over binary websockets.", - "properties": { - "contents": { - "description": "The contents of the file.", - "items": { - "format": "uint8", - "minimum": 0, - "type": "integer" - }, - "type": "array" - }, - "name": { - "description": "The name of the file.", - "type": "string" - } - }, - "required": [ - "contents", - "name" - ], - "type": "object" - }, - "RtcIceCandidateInit": { - "description": "ICECandidateInit is used to serialize ice candidates", - "properties": { - "candidate": { - "description": "The candidate string associated with the object.", - "type": "string" - }, - "sdpMLineIndex": { - "description": "The index (starting at zero) of the m-line in the SDP this candidate is associated with.", - "format": "uint16", - "minimum": 0, - "nullable": true, - "type": "integer" - }, - "sdpMid": { - "description": "The identifier of the \"media stream identification\" as defined in [RFC 8841](https://tools.ietf.org/html/rfc8841).", - "nullable": true, - "type": "string" - }, - "usernameFragment": { - "description": "The username fragment (as defined in [RFC 8445](https://tools.ietf.org/html/rfc8445#section-5.2.1)) associated with the object.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "candidate" - ], - "type": "object" - }, - "RtcSdpType": { - "description": "SDPType describes the type of an SessionDescription.", - "oneOf": [ - { - "description": "Unspecified indicates that the type is unspecified.", - "enum": [ - "unspecified" - ], - "type": "string" - }, - { - "description": "indicates that a description MUST be treated as an SDP offer.", - "enum": [ - "offer" - ], - "type": "string" - }, - { - "description": "indicates that a description MUST be treated as an SDP answer, but not a final answer. A description used as an SDP pranswer may be applied as a response to an SDP offer, or an update to a previously sent SDP pranswer.", - "enum": [ - "pranswer" - ], - "type": "string" - }, - { - "description": "indicates that a description MUST be treated as an SDP final answer, and the offer-answer exchange MUST be considered complete. A description used as an SDP answer may be applied as a response to an SDP offer or as an update to a previously sent SDP pranswer.", - "enum": [ - "answer" - ], - "type": "string" + "created_at", + "id", + "output_unit", + "src_format", + "status", + "type", + "updated_at" + ] }, { - "description": "indicates that a description MUST be treated as canceling the current SDP negotiation and moving the SDP offer and answer back to what it was in the previous stable state. Note the local or remote SDP descriptions in the previous stable state could be null if there has not yet been a successful offer-answer negotiation.", - "enum": [ - "rollback" - ], - "type": "string" - } - ] - }, - "RtcSessionDescription": { - "description": "SessionDescription is used to expose local and remote session descriptions.", - "properties": { - "sdp": { - "description": "SDP string.", - "type": "string" - }, - "type": { - "allOf": [ - { - "$ref": "#/components/schemas/RtcSdpType" + "description": "A file density.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "density": { + "nullable": true, + "description": "The resulting density.", + "type": "number", + "format": "double" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "material_mass": { + "description": "The material mass as denoted by the user.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "material_mass_unit": { + "description": "The material mass unit.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" + } + ] + }, + "output_unit": { + "description": "The output unit for the density.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitDensity" + } + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "file_density" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } - ], - "description": "SDP type." - } - }, - "required": [ - "sdp", - "type" - ], - "type": "object" - }, - "SceneSelectionType": { - "description": "The type of scene selection change", - "oneOf": [ - { - "description": "Replaces the selection", - "enum": [ - "replace" - ], - "type": "string" - }, - { - "description": "Adds to the selection", - "enum": [ - "add" - ], - "type": "string" - }, - { - "description": "Removes from the selection", - "enum": [ - "remove" - ], - "type": "string" - } - ] - }, - "SceneToolType": { - "description": "The type of scene's active tool", - "enum": [ - "camera_revolve", - "select", - "move", - "sketch_line", - "sketch_curve", - "sketch_curve_mod" - ], - "type": "string" - }, - "SelectGet": { - "description": "The response from the `SelectGet` command.", - "properties": { - "entity_ids": { - "description": "The UUIDs of the selected entities.", - "items": { - "format": "uuid", - "type": "string" }, - "type": "array" - } - }, - "required": [ - "entity_ids" - ], - "type": "object" - }, - "SelectWithPoint": { - "description": "The response from the `SelectWithPoint` command.", - "properties": { - "entity_id": { - "description": "The UUID of the entity that was selected.", - "format": "uuid", - "nullable": true, - "type": "string" - } - }, - "type": "object" - }, - "Session": { - "description": "An authentication session.\n\nFor our UIs, these are automatically created by Next.js.", - "properties": { - "created_at": { - "description": "The date and time the session was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "expires": { - "description": "The date and time the session expires.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "id": { - "description": "The unique identifier for the session.", - "type": "string" + "required": [ + "created_at", + "id", + "material_mass_unit", + "output_unit", + "src_format", + "status", + "type", + "updated_at" + ] }, - "session_token": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" + { + "description": "A file surface area.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "output_unit": { + "description": "The output unit for the surface area.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitArea" + } + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "surface_area": { + "nullable": true, + "description": "The resulting surface area.", + "type": "number", + "format": "double" + }, + "type": { + "type": "string", + "enum": [ + "file_surface_area" + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } - ], - "description": "The session token." - }, - "updated_at": { - "description": "The date and time the session was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "user_id": { - "description": "The user ID of the user that the session belongs to.", - "type": "string" - } - }, - "required": [ - "created_at", - "expires", - "session_token", - "updated_at" - ], - "type": "object" - }, - "Solid3dGetAllEdgeFaces": { - "description": "The response from the `Solid3dGetAllEdgeFaces` command.", - "properties": { - "faces": { - "description": "The UUIDs of the faces.", - "items": { - "format": "uuid", - "type": "string" }, - "type": "array" + "required": [ + "created_at", + "id", + "output_unit", + "src_format", + "status", + "type", + "updated_at" + ] } - }, - "required": [ - "faces" - ], - "type": "object" + ] }, - "Solid3dGetAllOppositeEdges": { - "description": "The response from the `Solid3dGetAllOppositeEdges` command.", + "AsyncApiCallResultsPage": { + "description": "A single page of results", + "type": "object", "properties": { - "edges": { - "description": "The UUIDs of the edges.", + "items": { + "description": "list of items on this page of results", + "type": "array", "items": { - "format": "uuid", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "edges" - ], - "type": "object" - }, - "Solid3dGetNextAdjacentEdge": { - "description": "The response from the `Solid3dGetNextAdjacentEdge` command.", - "properties": { - "edge": { - "description": "The UUID of the edge.", - "format": "uuid", + "$ref": "#/components/schemas/AsyncApiCall" + } + }, + "next_page": { "nullable": true, - "type": "string" - } - }, - "type": "object" - }, - "Solid3dGetOppositeEdge": { - "description": "The response from the `Solid3dGetOppositeEdge` command.", - "properties": { - "edge": { - "description": "The UUID of the edge.", - "format": "uuid", + "description": "token used to fetch the next page of results (if any)", "type": "string" } }, "required": [ - "edge" - ], - "type": "object" - }, - "Solid3dGetPrevAdjacentEdge": { - "description": "The response from the `Solid3dGetPrevAdjacentEdge` command.", - "properties": { - "edge": { - "description": "The UUID of the edge.", - "format": "uuid", - "nullable": true, - "type": "string" - } - }, - "type": "object" + "items" + ] }, - "StlStorage": { - "description": "Export storage.", + "AsyncApiCallType": { + "description": "The type of async API call.", "oneOf": [ { - "description": "Plaintext encoding.", + "description": "File conversion.", + "type": "string", "enum": [ - "ascii" - ], - "type": "string" + "file_conversion" + ] }, { - "description": "Binary STL encoding.\n\nThis is the default setting.", + "description": "File volume.", + "type": "string", "enum": [ - "binary" - ], - "type": "string" - } - ] - }, - "SuccessWebSocketResponse": { - "description": "Successful Websocket response.", - "properties": { - "request_id": { - "description": "Which request this is a response to. If the request was a modeling command, this is the modeling command ID. If no request ID was sent, this will be null.", - "format": "uuid", - "nullable": true, - "type": "string" + "file_volume" + ] }, - "resp": { - "allOf": [ - { - "$ref": "#/components/schemas/OkWebSocketResponseData" - } - ], - "description": "The data sent with a successful response. This will be flattened into a 'type' and 'data' field." + { + "description": "File center of mass.", + "type": "string", + "enum": [ + "file_center_of_mass" + ] }, - "success": { - "description": "Always true", - "type": "boolean" - } - }, - "required": [ - "resp", - "success" - ], - "type": "object" - }, - "SurfaceArea": { - "description": "The surface area response.", - "properties": { - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitArea" - } - ], - "description": "The output unit for the surface area." + { + "description": "File mass.", + "type": "string", + "enum": [ + "file_mass" + ] }, - "surface_area": { - "description": "The surface area.", - "format": "double", - "type": "number" - } - }, - "required": [ - "output_unit", - "surface_area" - ], - "type": "object" - }, - "System": { - "description": "Co-ordinate system definition.\n\nThe `up` axis must be orthogonal to the `forward` axis.\n\nSee [cglearn.eu] for background reading.\n\n[cglearn.eu](https://cglearn.eu/pub/computer-graphics/introduction-to-geometry#material-coordinate-systems-1)", - "properties": { - "forward": { - "allOf": [ - { - "$ref": "#/components/schemas/AxisDirectionPair" - } - ], - "description": "Axis the front face of a model looks along." + { + "description": "File density.", + "type": "string", + "enum": [ + "file_density" + ] }, - "up": { - "allOf": [ - { - "$ref": "#/components/schemas/AxisDirectionPair" - } - ], - "description": "Axis pointing up and away from a model." - } - }, - "required": [ - "forward", - "up" - ], - "type": "object" - }, - "TakeSnapshot": { - "description": "The response from the `TakeSnapshot` command.", - "properties": { - "contents": { - "description": "Contents of the image.", - "format": "byte", - "title": "String", - "type": "string" + { + "description": "File surface area.", + "type": "string", + "enum": [ + "file_surface_area" + ] } - }, - "required": [ - "contents" - ], - "type": "object" + ] }, - "UnitAngle": { - "description": "The valid types of angle formats.", + "Axis": { + "description": "Co-ordinate axis specifier.\n\nSee [cglearn.eu] for background reading.\n\n[cglearn.eu]: https://cglearn.eu/pub/computer-graphics/introduction-to-geometry#material-coordinate-systems-1", "oneOf": [ { - "description": "Degrees ", + "description": "'Y' axis.", + "type": "string", "enum": [ - "degrees" - ], - "type": "string" + "y" + ] }, { - "description": "Radians ", + "description": "'Z' axis.", + "type": "string", "enum": [ - "radians" - ], - "type": "string" + "z" + ] } ] }, - "UnitAngleConversion": { - "description": "Result of converting between units.", + "AxisDirectionPair": { + "description": "An [`Axis`] paired with a [`Direction`].", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { + "axis": { + "description": "Axis specifier.", "allOf": [ { - "$ref": "#/components/schemas/UnitAngle" + "$ref": "#/components/schemas/Axis" } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + ] }, - "output_unit": { + "direction": { + "description": "Specifies which direction the axis is pointing.", "allOf": [ { - "$ref": "#/components/schemas/UnitAngle" + "$ref": "#/components/schemas/Direction" } - ], - "description": "The output format of the unit conversion." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", + ] + } + }, + "required": [ + "axis", + "direction" + ] + }, + "BillingInfo": { + "description": "The billing information for payments.", + "type": "object", + "properties": { + "address": { "nullable": true, - "title": "DateTime", - "type": "string" - }, - "status": { + "description": "The address of the customer.", "allOf": [ { - "$ref": "#/components/schemas/ApiCallStatus" + "$ref": "#/components/schemas/NewAddress" } - ], - "description": "The status of the API call." + ] }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", + "name": { + "description": "The name of the customer.", "type": "string" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "phone": { + "title": "String", + "description": "The phone for the customer.", + "default": "", + "type": "string", + "format": "phone" + } + } + }, + "CacheMetadata": { + "description": "Metadata about our cache.\n\nThis is mostly used for internal purposes and debugging.", + "type": "object", + "properties": { + "ok": { + "description": "If the cache returned an ok response from ping.", + "type": "boolean" } }, "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" + "ok" + ] }, - "UnitArea": { - "description": "The valid types of area units.", + "CameraDragInteractionType": { + "description": "The type of camera drag interaction.", "oneOf": [ { - "description": "Square centimeters ", + "description": "Camera pan", + "type": "string", "enum": [ - "cm2" - ], - "type": "string" + "pan" + ] }, { - "description": "Square decimeters ", + "description": "Camera rotate (revolve/orbit)", + "type": "string", "enum": [ - "dm2" - ], - "type": "string" + "rotate" + ] }, { - "description": "Square feet ", + "description": "Camera zoom (increase or decrease distance to reference point center)", + "type": "string", "enum": [ - "ft2" - ], + "zoom" + ] + } + ] + }, + "CardDetails": { + "description": "The card details of a payment method.", + "type": "object", + "properties": { + "brand": { + "description": "Card brand.\n\nCan be `amex`, `diners`, `discover`, `jcb`, `mastercard`, `unionpay`, `visa`, or `unknown`.", "type": "string" }, - { - "description": "Square inches ", - "enum": [ - "in2" - ], - "type": "string" + "checks": { + "description": "Checks on Card address and CVC if provided.", + "default": {}, + "allOf": [ + { + "$ref": "#/components/schemas/PaymentMethodCardChecks" + } + ] }, - { - "description": "Square kilometers ", - "enum": [ - "km2" - ], + "country": { + "description": "Two-letter ISO code representing the country of the card.", "type": "string" }, - { - "description": "Square meters ", - "enum": [ - "m2" - ], + "exp_month": { + "description": "Two-digit number representing the card's expiration month.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "exp_year": { + "description": "Four-digit number representing the card's expiration year.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "fingerprint": { + "description": "Uniquely identifies this particular card number.", "type": "string" }, - { - "description": "Square millimeters ", - "enum": [ - "mm2" - ], + "funding": { + "description": "Card funding type.\n\nCan be `credit`, `debit`, `prepaid`, or `unknown`.", "type": "string" }, - { - "description": "Square yards ", - "enum": [ - "yd2" - ], + "last4": { + "description": "The last four digits of the card.", "type": "string" } - ] + } }, - "UnitAreaConversion": { - "description": "Result of converting between units.", + "CenterOfMass": { + "description": "The center of mass response.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { + "center_of_mass": { + "description": "The center of mass.", "allOf": [ { - "$ref": "#/components/schemas/Uuid" + "$ref": "#/components/schemas/Point3d" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + ] }, - "input_unit": { + "output_unit": { + "description": "The output unit for the center of mass.", "allOf": [ { - "$ref": "#/components/schemas/UnitArea" + "$ref": "#/components/schemas/UnitLength" } - ], - "description": "The source format of the unit conversion." + ] + } + }, + "required": [ + "center_of_mass", + "output_unit" + ] + }, + "ClientMetrics": { + "description": "ClientMetrics contains information regarding the state of the peer.", + "type": "object", + "properties": { + "rtc_frames_decoded": { + "description": "Counter of the number of WebRTC frames that the client has decoded during this session.", + "type": "integer", + "format": "uint64", + "minimum": 0 }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "rtc_frames_dropped": { + "description": "Counter of the number of WebRTC frames the client has dropped during this session.", + "type": "integer", + "format": "uint32", + "minimum": 0 }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitArea" - } - ], - "description": "The output format of the unit conversion." + "rtc_frames_per_second": { + "description": "Current number of frames being rendered per second. A good target is 60 frames per second, but it can fluctuate depending on network conditions.", + "type": "integer", + "format": "uint8", + "minimum": 0 }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", + "rtc_frames_received": { + "description": "Counter of the number of WebRTC frames that the client has received during this session.", + "type": "integer", + "format": "uint64", + "minimum": 0 + }, + "rtc_freeze_count": { + "description": "Number of times the WebRTC playback has frozen. This is usually due to network conditions.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "rtc_jitter_sec": { + "description": "Amount of \"jitter\" in the WebRTC session. Network latency is the time it takes a packet to traverse the network. The amount that the latency varies is the jitter. Video latency is the time it takes to render a frame sent by the server (including network latency). A low jitter means the video latency can be reduced without impacting smooth playback. High jitter means clients will increase video latency to ensure smooth playback.", + "type": "number", + "format": "float" + }, + "rtc_keyframes_decoded": { + "description": "Number of \"key frames\" decoded in the underlying h.264 stream. A key frame is an expensive (bandwidth-wise) \"full image\" of the video frame. Data after the keyframe become -- effectively -- \"diff\" operations on that key frame. The Engine will only send a keyframe if required, which is an indication that some of the \"diffs\" have been lost, usually an indication of poor network conditions. We like this metric to understand times when the connection has had to recover.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "rtc_total_freezes_duration_sec": { + "description": "Number of seconds of frozen video the user has been subjected to.", + "type": "number", + "format": "float" + } + }, + "required": [ + "rtc_frames_decoded", + "rtc_frames_dropped", + "rtc_frames_per_second", + "rtc_frames_received", + "rtc_freeze_count", + "rtc_jitter_sec", + "rtc_keyframes_decoded", + "rtc_total_freezes_duration_sec" + ] + }, + "Cluster": { + "description": "Cluster information.", + "type": "object", + "properties": { + "addr": { "nullable": true, - "title": "DateTime", + "description": "The IP address of the cluster.", "type": "string" }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "auth_timeout": { + "description": "The auth timeout of the cluster.", + "default": 0, + "type": "integer", + "format": "int64" }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "cluster_port": { + "description": "The port of the cluster.", + "default": 0, + "type": "integer", + "format": "int64" }, - "user_id": { - "description": "The user ID of the user who created the API call.", + "name": { + "description": "The name of the cluster.", + "default": "", "type": "string" + }, + "tls_timeout": { + "description": "The TLS timeout for the cluster.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "urls": { + "description": "The urls of the cluster.", + "default": [], + "type": "array", + "items": { + "type": "string" + } } - }, - "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" + } }, - "UnitCurrent": { - "description": "The valid types of current units.", + "CodeLanguage": { + "description": "The language code is written in.", "oneOf": [ { - "description": "Amperes ", - "enum": [ - "amperes" - ], - "type": "string" - }, - { - "description": "Microamperes ", + "description": "The `go` programming language.", + "type": "string", "enum": [ - "microamperes" - ], - "type": "string" + "go" + ] }, { - "description": "Milliamperes ", + "description": "The `python` programming language.", + "type": "string", "enum": [ - "milliamperes" - ], - "type": "string" + "python" + ] }, { - "description": "Nanoamperes ", + "description": "The `node` programming language.", + "type": "string", "enum": [ - "nanoamperes" - ], - "type": "string" + "node" + ] } ] }, - "UnitCurrentConversion": { - "description": "Result of converting between units.", + "CodeOutput": { + "description": "Output of the code being executed.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "output_files": { + "description": "The contents of the files requested if they were passed.", + "type": "array", + "items": { + "$ref": "#/components/schemas/OutputFile" + } }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", + "stderr": { + "description": "The stderr of the code.", + "default": "", "type": "string" }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, + "stdout": { + "description": "The stdout of the code.", + "default": "", "type": "string" + } + } + }, + "Color": { + "description": "An RGBA color", + "type": "object", + "properties": { + "a": { + "description": "Alpha", + "type": "number", + "format": "float" }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "b": { + "description": "Blue", + "type": "number", + "format": "float" }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + "g": { + "description": "Green", + "type": "number", + "format": "float" }, - "input_unit": { + "r": { + "description": "Red", + "type": "number", + "format": "float" + } + }, + "required": [ + "a", + "b", + "g", + "r" + ] + }, + "Connection": { + "description": "Metadata about a pub-sub connection.\n\nThis is mostly used for internal purposes and debugging.", + "type": "object", + "properties": { + "auth_timeout": { + "description": "The auth timeout of the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "cluster": { + "description": "Information about the cluster.", + "default": { + "addr": null, + "auth_timeout": 0, + "cluster_port": 0, + "name": "", + "tls_timeout": 0, + "urls": [] + }, "allOf": [ { - "$ref": "#/components/schemas/UnitCurrent" + "$ref": "#/components/schemas/Cluster" } - ], - "description": "The source format of the unit conversion." + ] }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "config_load_time": { + "description": "The time the configuration was loaded.", + "type": "string", + "format": "date-time" }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitCurrent" - } - ], - "description": "The output format of the unit conversion." + "connections": { + "description": "The number of connections to the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "cores": { + "description": "The CPU core usage of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "status": { + "cpu": { + "description": "The CPU usage of the server.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "gateway": { + "description": "Information about the gateway.", + "default": { + "auth_timeout": 0, + "host": "", + "name": "", + "port": 0, + "tls_timeout": 0 + }, "allOf": [ { - "$ref": "#/components/schemas/ApiCallStatus" + "$ref": "#/components/schemas/Gateway" } - ], - "description": "The status of the API call." - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" - } - }, - "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" - }, - "UnitDensity": { - "description": "The valid types for density units.", - "oneOf": [ - { - "description": "Pounds per cubic feet.", - "enum": [ - "lb:ft3" - ], - "type": "string" - }, - { - "description": "Kilograms per cubic meter.", - "enum": [ - "kg:m3" - ], - "type": "string" - } - ] - }, - "UnitEnergy": { - "description": "The valid types of energy units.", - "oneOf": [ - { - "description": "British Thermal Unit (BTU) ", - "enum": [ - "btu" - ], - "type": "string" - }, - { - "description": "Electron Volts (eV) ", - "enum": [ - "electronvolts" - ], - "type": "string" - }, - { - "description": "Joules (or watt-seconds) ", - "enum": [ - "joules" - ], - "type": "string" + ] }, - { - "description": "Kilocalories (often just called calories) ", - "enum": [ - "kilocalories" - ], + "git_commit": { + "description": "The git commit.", + "default": "", "type": "string" }, - { - "description": "Kilowatt hours (kWh) ", - "enum": [ - "kilowatt_hours" - ], + "go": { + "description": "The go version.", + "default": "", "type": "string" }, - { - "description": "Watt hours (Wh) ", - "enum": [ - "watt_hours" - ], - "type": "string" - } - ] - }, - "UnitEnergyConversion": { - "description": "Result of converting between units.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "gomaxprocs": { + "description": "`GOMAXPROCS` of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", + "host": { + "description": "The host of the server.", + "type": "string", + "format": "ip" + }, + "http_base_path": { + "description": "The http base path of the server.", + "default": "", "type": "string" }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, + "http_host": { + "description": "The http host of the server.", + "default": "", "type": "string" }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "http_port": { + "description": "The http port of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + "http_req_stats": { + "description": "HTTP request statistics.", + "type": "object", + "additionalProperties": { + "type": "integer", + "format": "int64" + } }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitEnergy" - } - ], - "description": "The source format of the unit conversion." + "https_port": { + "description": "The https port of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "in_bytes": { + "description": "The count of inbound bytes for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "output_unit": { + "in_msgs": { + "description": "The number of inbound messages for the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "jetstream": { + "description": "Jetstream information.", + "default": { + "config": { + "domain": "", + "max_memory": 0, + "max_storage": 0, + "store_dir": "" + }, + "meta": { + "cluster_size": 0, + "leader": "", + "name": "" + }, + "stats": { + "accounts": 0, + "api": { + "errors": 0, + "inflight": 0, + "total": 0 + }, + "ha_assets": 0, + "memory": 0, + "reserved_memory": 0, + "reserved_store": 0, + "store": 0 + } + }, "allOf": [ { - "$ref": "#/components/schemas/UnitEnergy" + "$ref": "#/components/schemas/Jetstream" } - ], - "description": "The output format of the unit conversion." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + ] }, - "status": { + "leaf": { + "description": "Information about leaf nodes.", + "default": { + "auth_timeout": 0, + "host": "", + "port": 0, + "tls_timeout": 0 + }, "allOf": [ { - "$ref": "#/components/schemas/ApiCallStatus" + "$ref": "#/components/schemas/LeafNode" } - ], - "description": "The status of the API call." + ] }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "leafnodes": { + "description": "The number of leaf nodes for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" - } - }, - "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" - }, - "UnitForce": { - "description": "The valid types of force units.", - "oneOf": [ - { - "description": "Dynes ", - "enum": [ - "dynes" - ], - "type": "string" + "max_connections": { + "description": "The max connections of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - { - "description": "Kiloponds ", - "enum": [ - "kiloponds" - ], - "type": "string" + "max_control_line": { + "description": "The max control line of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - { - "description": "Micronewtons ", - "enum": [ - "micronewtons" - ], - "type": "string" + "max_payload": { + "description": "The max payload of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - { - "description": "Millinewtons ", - "enum": [ - "millinewtons" - ], - "type": "string" + "max_pending": { + "description": "The max pending of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - { - "description": "Newtons ", - "enum": [ - "newtons" - ], - "type": "string" + "mem": { + "description": "The memory usage of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - { - "description": "Poundals ", - "enum": [ - "poundals" - ], - "type": "string" + "now": { + "description": "The time now.", + "type": "string", + "format": "date-time" }, - { - "description": "Pounds ", - "enum": [ - "pounds" - ], - "type": "string" - } - ] - }, - "UnitForceConversion": { - "description": "Result of converting between units.", - "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "out_bytes": { + "description": "The count of outbound bytes for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" + "out_msgs": { + "description": "The number of outbound messages for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" + "ping_interval": { + "description": "The ping interval of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "ping_max": { + "description": "The ping max of the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "port": { + "description": "The port of the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "proto": { + "description": "The protocol version.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "remotes": { + "description": "The number of remotes for the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "routes": { + "description": "The number of routes for the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "server_id": { + "description": "The server ID.", + "default": "", + "type": "string" }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + "server_name": { + "description": "The server name.", + "default": "", + "type": "string" }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitForce" - } - ], - "description": "The source format of the unit conversion." + "slow_consumers": { + "description": "The number of slow consumers for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "start": { + "description": "When the server was started.", + "type": "string", + "format": "date-time" }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitForce" - } - ], - "description": "The output format of the unit conversion." + "subscriptions": { + "description": "The number of subscriptions for the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", + "system_account": { + "description": "The system account.", + "default": "", "type": "string" }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "tls_timeout": { + "description": "The TLS timeout of the server.", + "default": 0, + "type": "integer", + "format": "int64" }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", + "total_connections": { + "description": "The total number of connections to the server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "uptime": { + "description": "The uptime of the server.", + "default": "", "type": "string" }, - "user_id": { - "description": "The user ID of the user who created the API call.", + "version": { + "description": "The version of the service.", + "default": "", "type": "string" + }, + "write_deadline": { + "description": "The write deadline of the server.", + "default": 0, + "type": "integer", + "format": "int64" } }, "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" + "config_load_time", + "host", + "http_req_stats", + "now", + "start" + ] }, - "UnitFrequency": { - "description": "The valid types of frequency units.", - "oneOf": [ - { - "description": "Gigahertz ", - "enum": [ - "gigahertz" - ], - "type": "string" - }, - { - "description": "Hertz ", - "enum": [ - "hertz" - ], - "type": "string" - }, - { - "description": "Kilohertz ", - "enum": [ - "kilohertz" - ], - "type": "string" - }, - { - "description": "Megahertz ", - "enum": [ - "megahertz" - ], - "type": "string" + "CountryCode": { + "description": "An ISO-3166 alpha-2 country code. Always uppercase.", + "type": "string" + }, + "Coupon": { + "description": "The resource representing a Coupon.", + "type": "object", + "properties": { + "amount_off": { + "nullable": true, + "title": "double", + "description": "Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.", + "type": "number", + "format": "money-usd" }, - { - "description": "Microhertz ", - "enum": [ - "microhertz" - ], - "type": "string" + "deleted": { + "description": "Always true for a deleted object.", + "default": false, + "type": "boolean" }, - { - "description": "Millihertz ", - "enum": [ - "millihertz" - ], + "id": { + "description": "Unique identifier for the object.", "type": "string" }, + "percent_off": { + "nullable": true, + "description": "Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon.\n\nFor example, a coupon with percent_off of 50 will make a %s100 invoice %s50 instead.", + "type": "number", + "format": "double" + } + } + }, + "CreatedAtSortMode": { + "description": "Supported set of sort modes for scanning by created_at only.\n\nCurrently, we only support scanning in ascending order.", + "oneOf": [ { - "description": "Nanohertz ", + "description": "Sort in increasing order of \"created_at\".", + "type": "string", "enum": [ - "nanohertz" - ], - "type": "string" + "created_at_ascending" + ] }, { - "description": "Terahertz ", + "description": "Sort in decreasing order of \"created_at\".", + "type": "string", "enum": [ - "terahertz" - ], - "type": "string" + "created_at_descending" + ] } ] }, - "UnitFrequencyConversion": { - "description": "Result of converting between units.", + "Currency": { + "description": "Currency is the list of supported currencies. Always lowercase.\n\nThis comes from the Stripe API docs: For more details see .", + "type": "string" + }, + "CurveGetControlPoints": { + "description": "The response from the `CurveGetControlPoints` command.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { + "control_points": { + "description": "Control points in the curve.", + "type": "array", + "items": { + "$ref": "#/components/schemas/Point3d" + } + } + }, + "required": [ + "control_points" + ] + }, + "CurveGetEndPoints": { + "description": "Endpoints of a curve", + "type": "object", + "properties": { + "end": { + "description": "End", "allOf": [ { - "$ref": "#/components/schemas/Uuid" + "$ref": "#/components/schemas/Point3d" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + ] }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { + "start": { + "description": "Start", "allOf": [ { - "$ref": "#/components/schemas/UnitFrequency" + "$ref": "#/components/schemas/Point3d" } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", + ] + } + }, + "required": [ + "end", + "start" + ] + }, + "CurveGetType": { + "description": "The response from the `CurveGetType` command.", + "type": "object", + "properties": { + "curve_type": { + "description": "Curve type", + "allOf": [ + { + "$ref": "#/components/schemas/CurveType" + } + ] + } + }, + "required": [ + "curve_type" + ] + }, + "CurveType": { + "description": "The type of Curve (embedded within path)", + "type": "string", + "enum": [ + "line", + "arc", + "nurbs" + ] + }, + "Customer": { + "description": "The resource representing a payment \"Customer\".", + "type": "object", + "properties": { + "address": { "nullable": true, - "type": "number" - }, - "output_unit": { + "description": "The customer's address.", "allOf": [ { - "$ref": "#/components/schemas/UnitFrequency" + "$ref": "#/components/schemas/NewAddress" } - ], - "description": "The output format of the unit conversion." + ] }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "balance": { + "title": "double", + "description": "Current balance, if any, being stored on the customer in the payments service.\n\nIf negative, the customer has credit to apply to their next invoice. If positive, the customer has an amount owed that will be added to their next invoice. The balance does not refer to any unpaid invoices; it solely takes into account amounts that have yet to be successfully applied to any invoice. This balance is only taken into account as invoices are finalized.", + "default": 0.0, + "type": "number", + "format": "money-usd" }, - "status": { + "created_at": { + "description": "Time at which the object was created.", + "type": "string", + "format": "date-time" + }, + "currency": { + "description": "Three-letter ISO code for the currency the customer can be charged in for recurring billing purposes.", + "default": "usd", "allOf": [ { - "$ref": "#/components/schemas/ApiCallStatus" + "$ref": "#/components/schemas/Currency" } - ], - "description": "The status of the API call." - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + ] }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" - } - }, - "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" - }, - "UnitLength": { - "description": "The valid types of length units.", - "oneOf": [ - { - "description": "Centimeters ", - "enum": [ - "cm" - ], - "type": "string" + "delinquent": { + "description": "When the customer's latest invoice is billed by charging automatically, `delinquent` is `true` if the invoice's latest charge failed.\n\nWhen the customer's latest invoice is billed by sending an invoice, `delinquent` is `true` if the invoice isn't paid by its due date. If an invoice is marked uncollectible by dunning, `delinquent` doesn't get reset to `false`.", + "default": false, + "type": "boolean" }, - { - "description": "Feet ", - "enum": [ - "ft" - ], - "type": "string" + "email": { + "description": "The customer's email address.", + "type": "string", + "format": "email" }, - { - "description": "Inches ", - "enum": [ - "in" - ], + "id": { + "description": "Unique identifier for the object.", "type": "string" }, - { - "description": "Meters ", - "enum": [ - "m" - ], - "type": "string" + "metadata": { + "description": "Set of key-value pairs.", + "default": {}, + "type": "object", + "additionalProperties": { + "type": "string" + } }, - { - "description": "Millimeters ", - "enum": [ - "mm" - ], + "name": { + "description": "The customer's full name or business name.", "type": "string" }, - { - "description": "Yards ", - "enum": [ - "yd" - ], - "type": "string" + "phone": { + "title": "String", + "description": "The customer's phone number.", + "default": "", + "type": "string", + "format": "phone" } + }, + "required": [ + "created_at" ] }, - "UnitLengthConversion": { - "description": "Result of converting between units.", + "CustomerBalance": { + "description": "A balance for a user.\n\nThis holds information about the financial balance for the user.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" + "description": "The date and time the balance was created.", + "type": "string", + "format": "date-time" }, "id": { + "description": "The unique identifier for the balance.", "allOf": [ { "$ref": "#/components/schemas/Uuid" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The source format of the unit conversion." + ] }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "monthly_credits_remaining": { + "title": "double", + "description": "The monthy credits remaining in the balance. This gets re-upped every month, but if the credits are not used for a month they do not carry over to the next month. It is a stable amount granted to the user per month.", + "type": "number", + "format": "money-usd" }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitLength" - } - ], - "description": "The output format of the unit conversion." + "pre_pay_cash_remaining": { + "title": "double", + "description": "The amount of pre-pay cash remaining in the balance. This number goes down as the user uses their pre-paid credits. The reason we track this amount is if a user ever wants to withdraw their pre-pay cash, we can use this amount to determine how much to give them. Say a user has $100 in pre-paid cash, their bill is worth, $50 after subtracting any other credits (like monthly etc.) Their bill is $50, their pre-pay cash remaining will be subtracted by 50 to pay the bill and their `pre_pay_credits_remaining` will be subtracted by 50 to pay the bill. This way if they want to withdraw money after, they can only withdraw $50 since that is the amount of cash they have remaining.", + "type": "number", + "format": "money-usd" }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "pre_pay_credits_remaining": { + "title": "double", + "description": "The amount of credits remaining in the balance. This is typically the amount of cash * some multiplier they get for pre-paying their account. This number lowers every time a bill is paid with the balance. This number increases every time a user adds funds to their balance. This may be through a subscription or a one off payment.", + "type": "number", + "format": "money-usd" }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." + "total_due": { + "title": "double", + "description": "This includes any outstanding, draft, or open invoices and any pending invoice items. This does not include any credits the user has on their account.", + "type": "number", + "format": "money-usd" }, "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The date and time the balance was last updated.", + "type": "string", + "format": "date-time" }, "user_id": { - "description": "The user ID of the user who created the API call.", + "description": "The user ID the balance belongs to.", "type": "string" } }, "required": [ "created_at", "id", - "input_unit", - "output_unit", - "status", + "monthly_credits_remaining", + "pre_pay_cash_remaining", + "pre_pay_credits_remaining", + "total_due", "updated_at" - ], - "type": "object" - }, - "UnitMass": { - "description": "The valid types of mass units.", - "oneOf": [ - { - "description": "Grams ", - "enum": [ - "g" - ], - "type": "string" - }, - { - "description": "Kilograms ", - "enum": [ - "kg" - ], - "type": "string" - }, - { - "description": "Pounds ", - "enum": [ - "lb" - ], - "type": "string" - } ] }, - "UnitMassConversion": { - "description": "Result of converting between units.", + "Density": { + "description": "The density response.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitMass" - } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + "density": { + "description": "The density.", + "type": "number", + "format": "double" }, "output_unit": { + "description": "The output unit for the density.", "allOf": [ { - "$ref": "#/components/schemas/UnitMass" + "$ref": "#/components/schemas/UnitDensity" } - ], - "description": "The output format of the unit conversion." + ] + } + }, + "required": [ + "density", + "output_unit" + ] + }, + "DeviceAccessTokenRequestForm": { + "description": "The form for a device access token request.", + "type": "object", + "properties": { + "client_id": { + "description": "The client ID.", + "type": "string", + "format": "uuid" }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + "device_code": { + "description": "The device code.", + "type": "string", + "format": "uuid" }, - "status": { + "grant_type": { + "description": "The grant type.", "allOf": [ { - "$ref": "#/components/schemas/ApiCallStatus" + "$ref": "#/components/schemas/OAuth2GrantType" } - ], - "description": "The status of the API call." - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "user_id": { - "description": "The user ID of the user who created the API call.", + ] + } + }, + "required": [ + "client_id", + "device_code", + "grant_type" + ] + }, + "DeviceAuthRequestForm": { + "description": "The request parameters for the OAuth 2.0 Device Authorization Grant flow.", + "type": "object", + "properties": { + "client_id": { + "description": "The client ID.", + "type": "string", + "format": "uuid" + } + }, + "required": [ + "client_id" + ] + }, + "DeviceAuthVerifyParams": { + "description": "The request parameters to verify the `user_code` for the OAuth 2.0 Device Authorization Grant.", + "type": "object", + "properties": { + "user_code": { + "description": "The user code.", "type": "string" } }, "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" + "user_code" + ] }, - "UnitPower": { - "description": "The valid types of power units.", + "Direction": { + "description": "Specifies the sign of a co-ordinate axis.", "oneOf": [ { - "description": "British thermal units (BTU) per minute ", - "enum": [ - "btu_per_minute" - ], - "type": "string" - }, - { - "description": "Horsepower (hp) ", - "enum": [ - "horsepower" - ], - "type": "string" - }, - { - "description": "Kilowatts ", + "description": "Increasing numbers.", + "type": "string", "enum": [ - "kilowatts" - ], - "type": "string" + "positive" + ] }, { - "description": "Metric horsepower (PS) ", + "description": "Decreasing numbers.", + "type": "string", "enum": [ - "metric_horsepower" - ], - "type": "string" + "negative" + ] + } + ] + }, + "Discount": { + "description": "The resource representing a Discount.", + "type": "object", + "properties": { + "coupon": { + "description": "The coupon that applied to create this discount.", + "allOf": [ + { + "$ref": "#/components/schemas/Coupon" + } + ] + } + }, + "required": [ + "coupon" + ] + }, + "EmailAuthenticationForm": { + "description": "The body of the form for email authentication.", + "type": "object", + "properties": { + "callback_url": { + "nullable": true, + "description": "The URL to redirect back to after we have authenticated.", + "type": "string", + "format": "uri" }, + "email": { + "description": "The user's email.", + "type": "string", + "format": "email" + } + }, + "required": [ + "email" + ] + }, + "EntityGetAllChildUuids": { + "description": "The response from the `EntityGetAllChildUuids` command.", + "type": "object", + "properties": { + "entity_ids": { + "description": "The UUIDs of the child entities.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } + } + }, + "required": [ + "entity_ids" + ] + }, + "EntityGetChildUuid": { + "description": "The response from the `EntityGetChildUuid` command.", + "type": "object", + "properties": { + "entity_id": { + "description": "The UUID of the child entity.", + "type": "string", + "format": "uuid" + } + }, + "required": [ + "entity_id" + ] + }, + "EntityGetNumChildren": { + "description": "The response from the `EntityGetNumChildren` command.", + "type": "object", + "properties": { + "num": { + "description": "The number of children the entity has.", + "type": "integer", + "format": "uint32", + "minimum": 0 + } + }, + "required": [ + "num" + ] + }, + "EntityGetParentId": { + "description": "The response from the `EntityGetParentId` command.", + "type": "object", + "properties": { + "entity_id": { + "description": "The UUID of the parent entity.", + "type": "string", + "format": "uuid" + } + }, + "required": [ + "entity_id" + ] + }, + "EntityType": { + "description": "The type of entity", + "type": "string", + "enum": [ + "entity", + "object", + "path", + "curve", + "solid2d", + "solid3d", + "edge", + "face", + "plane" + ] + }, + "Environment": { + "description": "The environment the server is running in.", + "oneOf": [ { - "description": "Microwatts ", + "description": "The development environment. This is for running locally.", + "type": "string", "enum": [ - "microwatts" - ], - "type": "string" + "DEVELOPMENT" + ] }, { - "description": "Millwatts ", + "description": "The preview environment. This is when PRs are created and a service is deployed for testing.", + "type": "string", "enum": [ - "milliwatts" - ], - "type": "string" + "PREVIEW" + ] }, { - "description": "Watts ", + "description": "The production environment.", + "type": "string", "enum": [ - "watts" - ], - "type": "string" + "PRODUCTION" + ] } ] }, - "UnitPowerConversion": { - "description": "Result of converting between units.", + "Error": { + "description": "Error information from a response.", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" - }, - "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" - }, - "error": { - "description": "The error the function returned, if any.", - "nullable": true, - "type": "string" - }, - "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitPower" - } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" - }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitPower" - } - ], - "description": "The output format of the unit conversion." - }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", - "nullable": true, - "title": "DateTime", + "error_code": { "type": "string" }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." - }, - "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", - "title": "DateTime", + "message": { "type": "string" }, - "user_id": { - "description": "The user ID of the user who created the API call.", + "request_id": { "type": "string" } }, "required": [ - "created_at", - "id", - "input_unit", - "output_unit", - "status", - "updated_at" - ], - "type": "object" + "message", + "request_id" + ] }, - "UnitPressure": { - "description": "The valid types of pressure units.", + "ErrorCode": { + "description": "The type of error sent by the KittyCAD API.", "oneOf": [ { - "description": "Atmospheres ", + "description": "Graphics engine failed to complete request, consider retrying", + "type": "string", "enum": [ - "atmospheres" - ], - "type": "string" + "internal_engine" + ] }, { - "description": "Bars ", + "description": "API failed to complete request, consider retrying", + "type": "string", "enum": [ - "bars" - ], - "type": "string" + "internal_api" + ] }, { - "description": "Hectopascals ", + "description": "User requested something geometrically or graphically impossible. Don't retry this request, as it's inherently impossible. Instead, read the error message and change your request.", + "type": "string", + "enum": [ + "bad_request" + ] + }, + { + "description": "Client sent invalid JSON.", + "type": "string", + "enum": [ + "invalid_json" + ] + }, + { + "description": "Client sent invalid BSON.", + "type": "string", "enum": [ - "hectopascals" - ], - "type": "string" + "invalid_bson" + ] }, { - "description": "Kilopascals ", + "description": "Client sent a message which is not accepted over this protocol.", + "type": "string", "enum": [ - "kilopascals" - ], - "type": "string" + "wrong_protocol" + ] }, { - "description": "Millibars ", + "description": "Problem sending data between client and KittyCAD API.", + "type": "string", "enum": [ - "millibars" - ], - "type": "string" + "connection_problem" + ] }, { - "description": "Pascals ", + "description": "Client sent a Websocket message type which the KittyCAD API does not handle.", + "type": "string", "enum": [ - "pascals" - ], - "type": "string" + "message_type_not_accepted" + ] }, { - "description": "Pounds per square inch (PSI) - ", + "description": "Client sent a Websocket message intended for WebRTC but it was configured as a WebRTC connection.", + "type": "string", "enum": [ - "psi" - ], + "message_type_not_accepted_for_web_r_t_c" + ] + } + ] + }, + "Export": { + "description": "The response from the `Export` endpoint.", + "type": "object", + "properties": { + "files": { + "description": "The files that were exported.", + "type": "array", + "items": { + "$ref": "#/components/schemas/ExportFile" + } + } + }, + "required": [ + "files" + ] + }, + "ExportFile": { + "description": "A file to be exported to the client.", + "type": "object", + "properties": { + "contents": { + "title": "String", + "description": "The contents of the file, base64 encoded.", + "type": "string", + "format": "byte" + }, + "name": { + "description": "The name of the file.", "type": "string" } + }, + "required": [ + "contents", + "name" ] }, - "UnitPressureConversion": { - "description": "Result of converting between units.", + "ExtendedUser": { + "description": "Extended user information.\n\nThis is mostly used for internal purposes. It returns a mapping of the user's information, including that of our third party services we use for users: MailChimp, Stripe, and Front", + "type": "object", "properties": { - "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", - "nullable": true, - "title": "DateTime", + "company": { + "description": "The user's company.", "type": "string" }, "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", "title": "DateTime", + "description": "The date and time the user was created.", + "type": "string", + "format": "date-time" + }, + "discord": { + "description": "The user's Discord handle.", + "type": "string" + }, + "email": { + "description": "The email address of the user.", + "type": "string", + "format": "email" + }, + "email_verified": { + "nullable": true, + "title": "DateTime", + "description": "The date and time the email address was verified.", + "type": "string", + "format": "date-time" + }, + "first_name": { + "description": "The user's first name.", "type": "string" }, - "error": { - "description": "The error the function returned, if any.", + "front_id": { "nullable": true, + "description": "The user's Front ID. This is mostly used for internal mapping.", + "type": "string" + }, + "github": { + "description": "The user's GitHub handle.", "type": "string" }, "id": { - "allOf": [ - { - "$ref": "#/components/schemas/Uuid" - } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + "description": "The unique identifier for the user.", + "type": "string" }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + "image": { + "title": "String", + "description": "The image avatar for the user. This is a URL.", + "type": "string", + "format": "uri" }, - "input_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitPressure" - } - ], - "description": "The source format of the unit conversion." + "last_name": { + "description": "The user's last name.", + "type": "string" }, - "output": { - "description": "The resulting value.", - "format": "double", + "mailchimp_id": { "nullable": true, - "type": "number" + "description": "The user's MailChimp ID. This is mostly used for internal mapping.", + "type": "string" }, - "output_unit": { - "allOf": [ - { - "$ref": "#/components/schemas/UnitPressure" - } - ], - "description": "The output format of the unit conversion." + "name": { + "description": "The name of the user. This is auto populated at first from the authentication provider (if there was a name). It can be updated by the user by updating their `first_name` and `last_name` fields.", + "type": "string" }, - "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", + "phone": { + "title": "String", + "description": "The user's phone number.", + "default": "", + "type": "string", + "format": "phone" + }, + "stripe_id": { "nullable": true, - "title": "DateTime", + "description": "The user's Stripe ID. This is mostly used for internal mapping.", "type": "string" }, - "status": { - "allOf": [ - { - "$ref": "#/components/schemas/ApiCallStatus" - } - ], - "description": "The status of the API call." - }, "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", "title": "DateTime", - "type": "string" - }, - "user_id": { - "description": "The user ID of the user who created the API call.", - "type": "string" + "description": "The date and time the user was last updated.", + "type": "string", + "format": "date-time" } }, "required": [ "created_at", - "id", - "input_unit", - "output_unit", - "status", + "image", "updated_at" - ], - "type": "object" + ] }, - "UnitTemperature": { - "description": "The valid types of temperature units.", - "oneOf": [ - { - "description": "Celsius ", - "enum": [ - "celsius" - ], - "type": "string" + "ExtendedUserResultsPage": { + "description": "A single page of results", + "type": "object", + "properties": { + "items": { + "description": "list of items on this page of results", + "type": "array", + "items": { + "$ref": "#/components/schemas/ExtendedUser" + } }, - { - "description": "Fahrenheit ", - "enum": [ - "fahrenheit" - ], + "next_page": { + "nullable": true, + "description": "token used to fetch the next page of results (if any)", "type": "string" + } + }, + "required": [ + "items" + ] + }, + "FailureWebSocketResponse": { + "description": "Unsuccessful Websocket response.", + "type": "object", + "properties": { + "errors": { + "description": "The errors that occurred.", + "type": "array", + "items": { + "$ref": "#/components/schemas/ApiError" + } + }, + "request_id": { + "nullable": true, + "description": "Which request this is a response to. If the request was a modeling command, this is the modeling command ID. If no request ID was sent, this will be null.", + "type": "string", + "format": "uuid" }, + "success": { + "description": "Always false", + "type": "boolean" + } + }, + "required": [ + "errors", + "success" + ] + }, + "FbxStorage": { + "description": "Describes the storage format of an FBX file.", + "oneOf": [ { - "description": "Kelvin ", + "description": "ASCII FBX encoding.", + "type": "string", "enum": [ - "kelvin" - ], - "type": "string" + "ascii" + ] }, { - "description": "Rankine ", + "description": "Binary FBX encoding.", + "type": "string", "enum": [ - "rankine" - ], - "type": "string" + "binary" + ] } ] }, - "UnitTemperatureConversion": { - "description": "Result of converting between units.", + "FileCenterOfMass": { + "description": "A file center of mass result.", + "type": "object", "properties": { + "center_of_mass": { + "nullable": true, + "description": "The resulting center of mass.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" }, "error": { - "description": "The error the function returned, if any.", "nullable": true, + "description": "The error the function returned, if any.", "type": "string" }, "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { "$ref": "#/components/schemas/Uuid" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." - }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + ] }, - "input_unit": { + "output_unit": { + "description": "The output unit for the center of mass.", "allOf": [ { - "$ref": "#/components/schemas/UnitTemperature" + "$ref": "#/components/schemas/UnitLength" } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + ] }, - "output_unit": { + "src_format": { + "description": "The source format of the file.", "allOf": [ { - "$ref": "#/components/schemas/UnitTemperature" + "$ref": "#/components/schemas/FileImportFormat" } - ], - "description": "The output format of the unit conversion." + ] }, "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, "status": { + "description": "The status of the API call.", "allOf": [ { "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "The status of the API call." + ] }, "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, "user_id": { "description": "The user ID of the user who created the API call.", @@ -10078,109 +10039,105 @@ "required": [ "created_at", "id", - "input_unit", "output_unit", + "src_format", "status", "updated_at" - ], - "type": "object" - }, - "UnitTorque": { - "description": "The valid types of torque units.", - "oneOf": [ - { - "description": "Newton metres ", - "enum": [ - "newton_metres" - ], - "type": "string" - }, - { - "description": "Pound foot ", - "enum": [ - "pound_foot" - ], - "type": "string" - } ] }, - "UnitTorqueConversion": { - "description": "Result of converting between units.", + "FileConversion": { + "description": "A file conversion.", + "type": "object", "properties": { "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" }, "error": { - "description": "The error the function returned, if any.", "nullable": true, + "description": "The error the function returned, if any.", "type": "string" }, "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { "$ref": "#/components/schemas/Uuid" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + ] }, - "input": { - "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" - }, - "input_unit": { + "output_format": { + "description": "The output format of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/UnitTorque" + "$ref": "#/components/schemas/FileExportFormat" } - ], - "description": "The source format of the unit conversion." + ] }, - "output": { - "description": "The resulting value.", - "format": "double", + "output_format_options": { "nullable": true, - "type": "number" + "description": "The output format options of the file conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/OutputFormat" + } + ] }, - "output_unit": { + "outputs": { + "description": "The converted files (if multiple file conversion), if completed, base64 encoded. The key of the map is the path of the output file.", + "type": "object", + "additionalProperties": { + "title": "String", + "type": "string", + "format": "byte" + } + }, + "src_format": { + "description": "The source format of the file conversion.", "allOf": [ { - "$ref": "#/components/schemas/UnitTorque" + "$ref": "#/components/schemas/FileImportFormat" + } + ] + }, + "src_format_options": { + "nullable": true, + "description": "The source format options of the file conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/InputFormat" } - ], - "description": "The output format of the unit conversion." + ] }, "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, "status": { + "description": "The status of the API call.", "allOf": [ { "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "The status of the API call." + ] }, "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, "user_id": { "description": "The user ID of the user who created the API call.", @@ -10190,158 +10147,98 @@ "required": [ "created_at", "id", - "input_unit", - "output_unit", + "output_format", + "src_format", "status", "updated_at" - ], - "type": "object" - }, - "UnitVolume": { - "description": "The valid types of volume units.", - "oneOf": [ - { - "description": "Cubic centimeters (cc or cm³) ", - "enum": [ - "cm3" - ], - "type": "string" - }, - { - "description": "Cubic feet (ft³) ", - "enum": [ - "ft3" - ], - "type": "string" - }, - { - "description": "Cubic inches (cu in or in³) ", - "enum": [ - "in3" - ], - "type": "string" - }, - { - "description": "Cubic meters (m³) ", - "enum": [ - "m3" - ], - "type": "string" - }, - { - "description": "Cubic yards (yd³) ", - "enum": [ - "yd3" - ], - "type": "string" - }, - { - "description": "US Fluid Ounces (fl oz) ", - "enum": [ - "usfloz" - ], - "type": "string" - }, - { - "description": "US Gallons (gal US) ", - "enum": [ - "usgal" - ], - "type": "string" - }, - { - "description": "Liters (l) ", - "enum": [ - "l" - ], - "type": "string" - }, - { - "description": "Milliliters (ml) ", - "enum": [ - "ml" - ], - "type": "string" - } ] }, - "UnitVolumeConversion": { - "description": "Result of converting between units.", + "FileDensity": { + "description": "A file density result.", + "type": "object", "properties": { "completed_at": { - "description": "The time and date the API call was completed.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, "created_at": { - "description": "The time and date the API call was created.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "density": { + "nullable": true, + "description": "The resulting density.", + "type": "number", + "format": "double" }, "error": { - "description": "The error the function returned, if any.", "nullable": true, + "description": "The error the function returned, if any.", "type": "string" }, "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { "$ref": "#/components/schemas/Uuid" } - ], - "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID." + ] }, - "input": { + "material_mass": { + "description": "The material mass as denoted by the user.", "default": 0.0, - "description": "The input value.", - "format": "double", - "type": "number" + "type": "number", + "format": "double" }, - "input_unit": { + "material_mass_unit": { + "description": "The material mass unit.", "allOf": [ { - "$ref": "#/components/schemas/UnitVolume" + "$ref": "#/components/schemas/UnitMass" } - ], - "description": "The source format of the unit conversion." - }, - "output": { - "description": "The resulting value.", - "format": "double", - "nullable": true, - "type": "number" + ] }, "output_unit": { + "description": "The output unit for the density.", "allOf": [ { - "$ref": "#/components/schemas/UnitVolume" + "$ref": "#/components/schemas/UnitDensity" + } + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" } - ], - "description": "The output format of the unit conversion." + ] }, "started_at": { - "description": "The time and date the API call was started.", - "format": "date-time", "nullable": true, "title": "DateTime", - "type": "string" + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, "status": { + "description": "The status of the API call.", "allOf": [ { "$ref": "#/components/schemas/ApiCallStatus" } - ], - "description": "The status of the API call." + ] }, "updated_at": { - "description": "The time and date the API call was last updated.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, "user_id": { "description": "The user ID of the user who created the API call.", @@ -10351,7401 +10248,7616 @@ "required": [ "created_at", "id", - "input_unit", + "material_mass_unit", "output_unit", + "src_format", "status", "updated_at" - ], - "type": "object" - }, - "UpdateUser": { - "description": "The user-modifiable parts of a User.", - "properties": { - "company": { - "description": "The user's company.", - "type": "string" - }, - "discord": { - "description": "The user's Discord handle.", - "type": "string" - }, - "first_name": { - "description": "The user's first name.", - "type": "string" - }, - "github": { - "description": "The user's GitHub handle.", - "type": "string" - }, - "last_name": { - "description": "The user's last name.", - "type": "string" - }, - "phone": { - "default": "", - "description": "The user's phone number.", - "format": "phone", - "title": "String", - "type": "string" - } - }, - "type": "object" + ] }, - "User": { - "description": "A user.", - "properties": { - "company": { - "description": "The user's company.", - "type": "string" + "FileExportFormat": { + "description": "The valid types of output file formats.", + "oneOf": [ + { + "description": "Autodesk Filmbox (FBX) format. ", + "type": "string", + "enum": [ + "fbx" + ] }, - "created_at": { - "description": "The date and time the user was created.", - "format": "date-time", - "title": "DateTime", - "type": "string" + { + "description": "Binary glTF 2.0.\n\nThis is a single binary with .glb extension.\n\nThis is better if you want a compressed format as opposed to the human readable glTF that lacks compression.", + "type": "string", + "enum": [ + "glb" + ] }, - "discord": { - "description": "The user's Discord handle.", - "type": "string" + { + "description": "glTF 2.0. Embedded glTF 2.0 (pretty printed).\n\nSingle JSON file with .gltf extension binary data encoded as base64 data URIs.\n\nThe JSON contents are pretty printed.\n\nIt is human readable, single file, and you can view the diff easily in a git commit.", + "type": "string", + "enum": [ + "gltf" + ] }, - "email": { - "description": "The email address of the user.", - "format": "email", - "type": "string" + { + "description": "The OBJ file format. It may or may not have an an attached material (mtl // mtllib) within the file, but we interact with it as if it does not.", + "type": "string", + "enum": [ + "obj" + ] }, - "email_verified": { - "description": "The date and time the email address was verified.", - "format": "date-time", - "nullable": true, - "title": "DateTime", - "type": "string" + { + "description": "The PLY file format. ", + "type": "string", + "enum": [ + "ply" + ] }, - "first_name": { - "description": "The user's first name.", - "type": "string" + { + "description": "The STEP file format. ", + "type": "string", + "enum": [ + "step" + ] }, - "github": { - "description": "The user's GitHub handle.", - "type": "string" + { + "description": "The STL file format. ", + "type": "string", + "enum": [ + "stl" + ] + } + ] + }, + "FileImportFormat": { + "description": "The valid types of source file formats.", + "oneOf": [ + { + "description": "Autodesk Filmbox (FBX) format. ", + "type": "string", + "enum": [ + "fbx" + ] }, - "id": { - "description": "The unique identifier for the user.", - "type": "string" + { + "description": "glTF 2.0.", + "type": "string", + "enum": [ + "gltf" + ] }, - "image": { - "description": "The image avatar for the user. This is a URL.", - "format": "uri", - "title": "String", - "type": "string" + { + "description": "The OBJ file format. It may or may not have an an attached material (mtl // mtllib) within the file, but we interact with it as if it does not.", + "type": "string", + "enum": [ + "obj" + ] }, - "last_name": { - "description": "The user's last name.", - "type": "string" + { + "description": "The PLY file format. ", + "type": "string", + "enum": [ + "ply" + ] }, - "name": { - "description": "The name of the user. This is auto populated at first from the authentication provider (if there was a name). It can be updated by the user by updating their `first_name` and `last_name` fields.", - "type": "string" + { + "description": "SolidWorks part (SLDPRT) format.", + "type": "string", + "enum": [ + "sldprt" + ] }, - "phone": { - "default": "", - "description": "The user's phone number.", - "format": "phone", - "title": "String", - "type": "string" + { + "description": "The STEP file format. ", + "type": "string", + "enum": [ + "step" + ] }, - "updated_at": { - "description": "The date and time the user was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" + { + "description": "The STL file format. ", + "type": "string", + "enum": [ + "stl" + ] } - }, - "required": [ - "created_at", - "image", - "updated_at" - ], - "type": "object" + ] }, - "UserResultsPage": { - "description": "A single page of results", + "FileMass": { + "description": "A file mass result.", + "type": "object", "properties": { - "items": { - "description": "list of items on this page of results", - "items": { - "$ref": "#/components/schemas/User" - }, - "type": "array" - }, - "next_page": { - "description": "token used to fetch the next page of results (if any)", + "completed_at": { "nullable": true, - "type": "string" - } - }, - "required": [ - "items" - ], - "type": "object" - }, - "Uuid": { - "description": "A uuid.\n\nA Version 4 UUID is a universally unique identifier that is generated using random numbers.", - "format": "uuid", - "type": "string" - }, - "VerificationToken": { - "description": "A verification token for a user.\n\nThis is typically used to verify a user's email address.", - "properties": { - "created_at": { - "description": "The date and time the verification token was created.", - "format": "date-time", "title": "DateTime", - "type": "string" + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, - "expires": { - "description": "The date and time the verification token expires.", - "format": "date-time", + "created_at": { "title": "DateTime", - "type": "string" - }, - "id": { - "description": "The token used for verification. This is used as the id for the table since it is unique per record.", - "type": "string" + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" }, - "identifier": { - "description": "The identifier for the user. This is typically the user's email address since that is what we are verifying.", + "error": { + "nullable": true, + "description": "The error the function returned, if any.", "type": "string" }, - "updated_at": { - "description": "The date and time the verification token was last updated.", - "format": "date-time", - "title": "DateTime", - "type": "string" - } - }, - "required": [ - "created_at", - "expires", - "updated_at" - ], - "type": "object" - }, - "Volume": { - "description": "The volume response.", - "properties": { - "output_unit": { + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { - "$ref": "#/components/schemas/UnitVolume" + "$ref": "#/components/schemas/Uuid" } - ], - "description": "The output unit for the volume." + ] }, - "volume": { - "description": "The volume.", - "format": "double", - "type": "number" - } - }, - "required": [ - "output_unit", - "volume" - ], - "type": "object" - }, - "WebSocketRequest": { - "description": "The websocket messages the server receives.", - "oneOf": [ - { - "description": "The trickle ICE candidate request.", - "properties": { - "candidate": { - "allOf": [ - { - "$ref": "#/components/schemas/RtcIceCandidateInit" - } - ], - "description": "Information about the ICE candidate." - }, - "type": { - "enum": [ - "trickle_ice" - ], - "type": "string" - } - }, - "required": [ - "candidate", - "type" - ], - "type": "object" + "mass": { + "nullable": true, + "description": "The resulting mass.", + "type": "number", + "format": "double" }, - { - "description": "The SDP offer request.", - "properties": { - "offer": { - "allOf": [ - { - "$ref": "#/components/schemas/RtcSessionDescription" - } - ], - "description": "The session description." - }, - "type": { - "enum": [ - "sdp_offer" - ], - "type": "string" - } - }, - "required": [ - "offer", - "type" - ], - "type": "object" + "material_density": { + "description": "The material density as denoted by the user.", + "default": 0.0, + "type": "number", + "format": "double" }, - { - "description": "The modeling command request.", - "properties": { - "cmd": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmd" - } - ], - "description": "Which command to submit to the Kittycad engine." - }, - "cmd_id": { - "allOf": [ - { - "$ref": "#/components/schemas/ModelingCmdId" - } - ], - "description": "ID of command being submitted." - }, - "type": { - "enum": [ - "modeling_cmd_req" - ], - "type": "string" + "material_density_unit": { + "description": "The material density unit.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitDensity" } - }, - "required": [ - "cmd", - "cmd_id", - "type" - ], - "type": "object" + ] }, - { - "description": "The client-to-server Ping to ensure the WebSocket stays alive.", - "properties": { - "type": { - "enum": [ - "ping" - ], - "type": "string" + "output_unit": { + "description": "The output unit for the mass.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" } - }, - "required": [ - "type" - ], - "type": "object" + ] }, - { - "description": "The response to a metrics collection request from the server.", - "properties": { - "metrics": { - "allOf": [ - { - "$ref": "#/components/schemas/ClientMetrics" - } - ], - "description": "Collected metrics from the Client's end of the engine connection." - }, - "type": { - "enum": [ - "metrics_response" - ], - "type": "string" + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" } - }, - "required": [ - "metrics", - "type" - ], - "type": "object" + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } + }, + "required": [ + "created_at", + "id", + "material_density_unit", + "output_unit", + "src_format", + "status", + "updated_at" ] }, - "WebSocketResponse": { - "anyOf": [ - { + "FileSurfaceArea": { + "description": "A file surface area result.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", "allOf": [ { - "$ref": "#/components/schemas/SuccessWebSocketResponse" + "$ref": "#/components/schemas/Uuid" } - ], - "description": "Response sent when a request succeeded." + ] }, - { + "output_unit": { + "description": "The output unit for the surface area.", "allOf": [ { - "$ref": "#/components/schemas/FailureWebSocketResponse" + "$ref": "#/components/schemas/UnitArea" } - ], - "description": "Response sent when a request did not succeed." - } - ], - "description": "Websocket responses can either be successful or unsuccessful. Slightly different schemas in either case." - } - } - }, - "info": { - "contact": { - "email": "api@kittycad.io", - "url": "https://kittycad.io" - }, - "description": "API server for KittyCAD", - "title": "KittyCAD API", - "version": "0.1.0" - }, - "openapi": "3.0.3", - "paths": { - "/": { - "get": { - "operationId": "get_schema", - "responses": { - "200": { - "content": { - "application/json": { - "schema": {} + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "surface_area": { + "nullable": true, + "description": "The resulting surface area.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get OpenAPI schema.", - "tags": [ - "meta" + "required": [ + "created_at", + "id", + "output_unit", + "src_format", + "status", + "updated_at" ] - } - }, - "/.well-known/ai-plugin.json": { - "get": { - "operationId": "get_ai_plugin_manifest", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AiPluginManifest" - } + }, + "FileSystemMetadata": { + "description": "Metadata about our file system.\n\nThis is mostly used for internal purposes and debugging.", + "type": "object", + "properties": { + "ok": { + "description": "If the file system passed a sanity check.", + "type": "boolean" + } + }, + "required": [ + "ok" + ] + }, + "FileVolume": { + "description": "A file volume result.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "output_unit": { + "description": "The output unit for the volume.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" } - } + ] + }, + "src_format": { + "description": "The source format of the file.", + "allOf": [ + { + "$ref": "#/components/schemas/FileImportFormat" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, - "4XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" + "volume": { + "nullable": true, + "description": "The resulting volume.", + "type": "number", + "format": "double" } }, - "summary": "Get AI plugin manifest.", - "tags": [ - "meta", - "hidden" + "required": [ + "created_at", + "id", + "output_unit", + "src_format", + "status", + "updated_at" ] - } - }, - "/_meta/info": { - "get": { - "description": "This includes information on any of our other distributed systems it is connected to.\nYou must be a KittyCAD employee to perform this request.", - "operationId": "get_metadata", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Metadata" - } + }, + "Gateway": { + "description": "Gateway information.", + "type": "object", + "properties": { + "auth_timeout": { + "description": "The auth timeout of the gateway.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "host": { + "description": "The host of the gateway.", + "default": "", + "type": "string" + }, + "name": { + "description": "The name of the gateway.", + "default": "", + "type": "string" + }, + "port": { + "description": "The port of the gateway.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "tls_timeout": { + "description": "The TLS timeout for the gateway.", + "default": 0, + "type": "integer", + "format": "int64" + } + } + }, + "GetEntityType": { + "description": "The response from the `GetEntityType` command.", + "type": "object", + "properties": { + "entity_type": { + "description": "The type of the entity.", + "allOf": [ + { + "$ref": "#/components/schemas/EntityType" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + } + }, + "required": [ + "entity_type" + ] + }, + "GetSketchModePlane": { + "description": "The plane for sketch mode.", + "type": "object", + "properties": { + "x_axis": { + "description": "The x axis.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "y_axis": { + "description": "The y axis.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + "z_axis": { + "description": "The z axis (normal).", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] } }, - "summary": "Get the metadata about our currently running server.", - "tags": [ - "meta", - "hidden" + "required": [ + "x_axis", + "y_axis", + "z_axis" ] - } - }, - "/ai/image-to-3d/{input_format}/{output_format}": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_image_to_3d", - "parameters": [ + }, + "GltfPresentation": { + "description": "Describes the presentation style of the glTF JSON.", + "oneOf": [ { - "description": "The format of the image being converted.", - "in": "path", - "name": "input_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/ImageType" - } + "description": "Condense the JSON into the smallest possible size.", + "type": "string", + "enum": [ + "compact" + ] }, { - "description": "The format the output file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } - } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + "description": "Expand the JSON into a more human readable format.\n\nThis is the default setting.", + "type": "string", + "enum": [ + "pretty" + ] } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" ] }, - "post": { - "description": "This is an alpha endpoint. It will change in the future. The current output is honestly pretty bad. So if you find this endpoint, you get what you pay for, which currently is nothing. But in the future will be made a lot better.", - "operationId": "create_image_to_3d", - "parameters": [ + "GltfStorage": { + "description": "Describes the storage format of a glTF 2.0 scene.", + "oneOf": [ { - "description": "The format of the image being converted.", - "in": "path", - "name": "input_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/ImageType" - } + "description": "Binary glTF 2.0.\n\nThis is a single binary with .glb extension.", + "type": "string", + "enum": [ + "binary" + ] }, { - "description": "The format the output file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } + "description": "Standard glTF 2.0.\n\nThis is a JSON file with .gltf extension paired with a separate binary blob file with .bin extension.", + "type": "string", + "enum": [ + "standard" + ] + }, + { + "description": "Embedded glTF 2.0.\n\nSingle JSON file with .gltf extension binary data encoded as base64 data URIs.\n\nThis is the default setting.", + "type": "string", + "enum": [ + "embedded" + ] } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" - } - } + ] + }, + "HighlightSetEntity": { + "description": "The response from the `HighlightSetEntity` command.", + "type": "object", + "properties": { + "entity_id": { + "nullable": true, + "description": "The UUID of the entity that was highlighted.", + "type": "string", + "format": "uuid" + }, + "sequence": { + "nullable": true, + "description": "If the client sent a sequence ID with its request, the backend sends it back.", + "type": "integer", + "format": "uint32", + "minimum": 0 + } + } + }, + "IceServer": { + "description": "Representation of an ICE server used for STUN/TURN Used to initiate WebRTC connections based on ", + "type": "object", + "properties": { + "credential": { + "nullable": true, + "description": "Credentials for a given TURN server.", + "type": "string" }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Mesh" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + "urls": { + "description": "URLs for a given STUN/TURN server. IceServer urls can either be a string or an array of strings But, we choose to always convert to an array of strings for consistency", + "type": "array", + "items": { + "type": "string" } }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + "username": { + "nullable": true, + "description": "Username for a given TURN server.", + "type": "string" } }, - "summary": "Generate a 3D model from an image.", - "tags": [ - "ai", - "beta", - "hidden" + "required": [ + "urls" ] - } - }, - "/ai/text-to-3d/{output_format}": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_text_to_3d", - "parameters": [ + }, + "ImageFormat": { + "description": "Enum containing the variety of image formats snapshots may be exported to.", + "oneOf": [ { - "description": "The format the output file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } + "description": ".png format", + "type": "string", + "enum": [ + "png" + ] + }, + { + "description": ".jpeg format", + "type": "string", + "enum": [ + "jpeg" + ] } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + ] + }, + "ImageType": { + "description": "An enumeration.", + "type": "string", + "enum": [ + "png", + "jpg" + ] + }, + "ImportFile": { + "description": "File to import into the current model", + "type": "object", + "properties": { + "data": { + "description": "The raw bytes of the file", + "type": "array", + "items": { + "type": "integer", + "format": "uint8", + "minimum": 0 } }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + "path": { + "description": "The file's full path, including file extension.", + "type": "string" } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "data", + "path" ] }, - "post": { - "description": "This is an alpha endpoint. It will change in the future. The current output is honestly pretty bad. So if you find this endpoint, you get what you pay for, which currently is nothing. But in the future will be made a lot better.", - "operationId": "create_text_to_3d", - "parameters": [ + "ImportFiles": { + "description": "Data from importing the files", + "type": "object", + "properties": { + "object_id": { + "description": "ID of the imported 3D models within the scene.", + "type": "string", + "format": "uuid" + } + }, + "required": [ + "object_id" + ] + }, + "InputFormat": { + "description": "Input format specifier.", + "oneOf": [ { - "description": "The format the output file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } + "description": "Autodesk Filmbox (FBX) format.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "fbx" + ] + } + }, + "required": [ + "type" + ] }, { - "description": "The prompt for the model.", - "in": "query", - "name": "prompt", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Mesh" - } + "description": "Binary glTF 2.0. We refer to this as glTF since that is how our customers refer to it, but this can also import binary glTF (glb).", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "gltf" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "type" + ] + }, + { + "description": "Wavefront OBJ format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "obj" + ] + }, + "units": { + "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc.\n\nDefaults to meters.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + } + }, + "required": [ + "coords", + "type", + "units" + ] + }, + { + "description": "The PLY Polygon File Format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "ply" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "units": { + "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] } - } + }, + "required": [ + "coords", + "type", + "units" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "SolidWorks part (SLDPRT) format.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "sldprt" + ] + } + }, + "required": [ + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Generate a 3D model from text.", - "tags": [ - "ai", - "beta", - "hidden" - ] - } - }, - "/api-call-metrics": { - "get": { - "description": "This endpoint requires authentication by a KittyCAD employee. The API calls are grouped by the parameter passed.", - "operationId": "get_api_call_metrics", - "parameters": [ { - "description": "What field to group the metrics by.", - "in": "query", - "name": "group_by", - "required": true, - "schema": { - "$ref": "#/components/schemas/ApiCallQueryGroupBy" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/ApiCallQueryGroup" - }, - "title": "Array_of_ApiCallQueryGroup", - "type": "array" - } + "description": "ISO 10303-21 (STEP) format.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "step" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "type" + ] + }, + { + "description": "*ST**ereo**L**ithography format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of input data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "stl" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "units": { + "description": "The units of the input data. This is very important for correct scaling and when calculating physics properties like mass, etc.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + } + }, + "required": [ + "coords", + "type", + "units" + ] + } + ] + }, + "Invoice": { + "description": "An invoice.", + "type": "object", + "properties": { + "amount_due": { + "title": "double", + "description": "Final amount due at this time for this invoice.\n\nIf the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.", + "default": 0.0, + "type": "number", + "format": "money-usd" + }, + "amount_paid": { + "title": "double", + "description": "The amount, in USD, that was paid.", + "default": 0.0, + "type": "number", + "format": "money-usd" + }, + "amount_remaining": { + "title": "double", + "description": "The amount remaining, in USD, that is due.", + "default": 0.0, + "type": "number", + "format": "money-usd" + }, + "attempt_count": { + "description": "Number of payment attempts made for this invoice, from the perspective of the payment retry schedule.\n\nAny payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule.", + "default": 0, + "type": "integer", + "format": "uint64", + "minimum": 0 + }, + "attempted": { + "description": "Whether an attempt has been made to pay the invoice.\n\nAn invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.", + "default": false, + "type": "boolean" + }, + "created_at": { + "description": "Time at which the object was created.", + "type": "string", + "format": "date-time" + }, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.", + "default": "usd", + "allOf": [ + { + "$ref": "#/components/schemas/Currency" } + ] + }, + "customer_email": { + "description": "The email address for the customer. Until the invoice is finalized, this field will equal customer.email. Once the invoice is finalized, this field will no longer be updated.", + "type": "string", + "format": "email" + }, + "customer_id": { + "description": "Customer ID. The unique identifier for the customer this invoice belongs to. This is the customer ID in the payments service, not our database customer ID.", + "type": "string" + }, + "default_payment_method": { + "description": "Default payment method.", + "type": "string" + }, + "description": { + "description": "Description of the invoice.", + "type": "string" + }, + "discounts": { + "description": "The discounts applied to the invoice. This is an array of discount objects.", + "type": "array", + "items": { + "$ref": "#/components/schemas/Discount" } }, - "4XX": { - "$ref": "#/components/responses/Error" + "id": { + "description": "Unique identifier for the object.", + "type": "string" + }, + "lines": { + "description": "The individual line items that make up the invoice.\n\n`lines` is sorted as follows: invoice items in reverse chronological order, followed by the subscription, if any.", + "type": "array", + "items": { + "$ref": "#/components/schemas/InvoiceLineItem" + } + }, + "metadata": { + "description": "Set of key-value pairs.", + "default": {}, + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "number": { + "description": "A unique, identifying string that appears on emails sent to the customer for this invoice.", + "type": "string" + }, + "paid": { + "description": "Whether payment was successfully collected for this invoice.\n\nAn invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.", + "default": false, + "type": "boolean" + }, + "pdf": { + "nullable": true, + "description": "The link to download the PDF for the invoice.", + "type": "string", + "format": "uri" + }, + "receipt_number": { + "description": "This is the transaction number that appears on email receipts sent for this invoice.", + "type": "string" + }, + "statement_descriptor": { + "description": "Extra information about an invoice for the customer's credit card statement.", + "type": "string" + }, + "status": { + "nullable": true, + "description": "The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`.\n\n[Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview).", + "allOf": [ + { + "$ref": "#/components/schemas/InvoiceStatus" + } + ] + }, + "subtotal": { + "title": "double", + "description": "Total of all subscriptions, invoice items, and prorations on the invoice before any invoice level discount or tax is applied.\n\nItem discounts are already incorporated.", + "default": 0.0, + "type": "number", + "format": "money-usd" + }, + "tax": { + "title": "double", + "description": "The amount of tax on this invoice.\n\nThis is the sum of all the tax amounts on this invoice.", + "default": 0.0, + "type": "number", + "format": "money-usd" + }, + "total": { + "title": "double", + "description": "Total after discounts and taxes.", + "default": 0.0, + "type": "number", + "format": "money-usd" }, - "5XX": { - "$ref": "#/components/responses/Error" + "url": { + "nullable": true, + "description": "The URL for the hosted invoice page, which allows customers to view and pay an invoice.", + "type": "string", + "format": "uri" } }, - "summary": "Get API call metrics.", - "tags": [ - "api-calls", - "hidden" + "required": [ + "created_at" ] - } - }, - "/api-calls": { - "get": { - "description": "This endpoint requires authentication by a KittyCAD employee. The API calls are returned in order of creation, with the most recently created API calls first.", - "operationId": "list_api_calls", - "parameters": [ - { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + }, + "InvoiceLineItem": { + "description": "An invoice line item.", + "type": "object", + "properties": { + "amount": { + "title": "double", + "description": "The amount, in USD.", + "default": 0.0, + "type": "number", + "format": "money-usd" }, - { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, + "currency": { + "description": "Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.", + "default": "usd", + "allOf": [ + { + "$ref": "#/components/schemas/Currency" + } + ] + }, + "description": { + "description": "The description.", + "type": "string" + }, + "id": { + "description": "Unique identifier for the object.", + "type": "string" + }, + "invoice_item": { + "description": "The ID of the invoice item associated with this line item if any.", + "type": "string" + }, + "metadata": { + "description": "Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object.\n\nSet of key-value pairs.", + "default": {}, + "type": "object", + "additionalProperties": { "type": "string" } + } + } + }, + "InvoiceStatus": { + "description": "An enum representing the possible values of an `Invoice`'s `status` field.", + "oneOf": [ + { + "description": "Deleted.", + "type": "string", + "enum": [ + "deleted" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "Draft.", + "type": "string", + "enum": [ + "draft" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Open.", + "type": "string", + "enum": [ + "open" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List API calls.", - "tags": [ - "api-calls", - "hidden" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/api-calls/{id}": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API call for the user.\nIf the user is not authenticated to view the specified API call, then it is not returned.\nOnly KittyCAD employees can view API calls for other users.", - "operationId": "get_api_call", - "parameters": [ { - "description": "The ID of the API call.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } + "description": "Paid.", + "type": "string", + "enum": [ + "paid" + ] + }, + { + "description": "Uncollectible.", + "type": "string", + "enum": [ + "uncollectible" + ] + }, + { + "description": "Void.", + "type": "string", + "enum": [ + "void" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiCallWithPrice" - } + ] + }, + "Jetstream": { + "description": "Jetstream information.", + "type": "object", + "properties": { + "config": { + "description": "The Jetstream config.", + "default": { + "domain": "", + "max_memory": 0, + "max_storage": 0, + "store_dir": "" + }, + "allOf": [ + { + "$ref": "#/components/schemas/JetstreamConfig" } + ] + }, + "meta": { + "description": "Meta information about the cluster.", + "default": { + "cluster_size": 0, + "leader": "", + "name": "" }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "allOf": [ + { + "$ref": "#/components/schemas/MetaClusterInfo" + } + ] + }, + "stats": { + "description": "Jetstream statistics.", + "default": { + "accounts": 0, + "api": { + "errors": 0, + "inflight": 0, + "total": 0 }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "ha_assets": 0, + "memory": 0, + "reserved_memory": 0, + "reserved_store": 0, + "store": 0 + }, + "allOf": [ + { + "$ref": "#/components/schemas/JetstreamStats" } - } + ] + } + } + }, + "JetstreamApiStats": { + "description": "Jetstream API statistics.", + "type": "object", + "properties": { + "errors": { + "description": "The number of errors.", + "default": 0, + "type": "integer", + "format": "int64" }, - "4XX": { - "$ref": "#/components/responses/Error" + "inflight": { + "description": "The number of inflight requests.", + "default": 0, + "type": "integer", + "format": "int64" }, - "5XX": { - "$ref": "#/components/responses/Error" + "total": { + "description": "The number of requests.", + "default": 0, + "type": "integer", + "format": "int64" } - }, - "summary": "Get details of an API call.", - "tags": [ - "api-calls", - "hidden" - ] - } - }, - "/apps/github/callback": { - "get": { - "description": "This is different than OAuth 2.0 authentication for users. This endpoint grants access for KittyCAD to access user's repos.\nThe user doesn't need KittyCAD OAuth authorization for this endpoint, this is purely for the GitHub permissions to access repos.", - "operationId": "apps_github_callback", - "requestBody": { - "content": { - "application/json": { - "schema": {} - } + } + }, + "JetstreamConfig": { + "description": "Jetstream configuration.", + "type": "object", + "properties": { + "domain": { + "description": "The domain.", + "default": "", + "type": "string" }, - "required": true - }, - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "max_memory": { + "description": "The max memory.", + "default": 0, + "type": "integer", + "format": "int64" }, - "4XX": { - "$ref": "#/components/responses/Error" + "max_storage": { + "description": "The max storage.", + "default": 0, + "type": "integer", + "format": "int64" }, - "5XX": { - "$ref": "#/components/responses/Error" + "store_dir": { + "description": "The store directory.", + "default": "", + "type": "string" } - }, - "summary": "Listen for callbacks to GitHub app authentication.", - "tags": [ - "apps", - "hidden" - ] - } - }, - "/apps/github/consent": { - "get": { - "description": "This is different than OAuth 2.0 authentication for users. This endpoint grants access for KittyCAD to access user's repos.\nThe user doesn't need KittyCAD OAuth authorization for this endpoint, this is purely for the GitHub permissions to access repos.", - "operationId": "apps_github_consent", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AppClientInfo" - } - } + } + }, + "JetstreamStats": { + "description": "Jetstream statistics.", + "type": "object", + "properties": { + "accounts": { + "description": "The number of accounts.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "api": { + "description": "API stats.", + "default": { + "errors": 0, + "inflight": 0, + "total": 0 }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "allOf": [ + { + "$ref": "#/components/schemas/JetstreamApiStats" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "ha_assets": { + "description": "The number of HA assets.", + "default": 0, + "type": "integer", + "format": "int64" }, - "5XX": { - "$ref": "#/components/responses/Error" + "memory": { + "description": "The memory used by the Jetstream server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "reserved_memory": { + "description": "The reserved memory for the Jetstream server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "reserved_store": { + "description": "The reserved storage for the Jetstream server.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "store": { + "description": "The storage used by the Jetstream server.", + "default": 0, + "type": "integer", + "format": "int64" } - }, - "summary": "Get the consent URL for GitHub app authentication.", - "tags": [ - "apps", - "hidden" - ] - } - }, - "/apps/github/webhook": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_apps_github_webhook", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + } + }, + "LeafNode": { + "description": "Leaf node information.", + "type": "object", + "properties": { + "auth_timeout": { + "description": "The auth timeout of the leaf node.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "host": { + "description": "The host of the leaf node.", + "default": "", + "type": "string" + }, + "port": { + "description": "The port of the leaf node.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "tls_timeout": { + "description": "The TLS timeout for the leaf node.", + "default": 0, + "type": "integer", + "format": "int64" + } + } + }, + "Mass": { + "description": "The mass response.", + "type": "object", + "properties": { + "mass": { + "description": "The mass.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output unit for the mass.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + ] } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "mass", + "output_unit" ] }, - "post": { - "description": "These come from the GitHub app.", - "operationId": "apps_github_webhook", - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "Mesh": { + "type": "object", + "properties": { + "mesh": { + "type": "string" + } + }, + "required": [ + "mesh" + ] + }, + "MetaClusterInfo": { + "description": "Jetstream statistics.", + "type": "object", + "properties": { + "cluster_size": { + "description": "The size of the cluster.", + "default": 0, + "type": "integer", + "format": "int64" + }, + "leader": { + "description": "The leader of the cluster.", + "default": "", + "type": "string" + }, + "name": { + "description": "The name of the cluster.", + "default": "", + "type": "string" + } + } + }, + "Metadata": { + "description": "Metadata about our currently running server.\n\nThis is mostly used for internal purposes and debugging.", + "type": "object", + "properties": { + "cache": { + "description": "Metadata about our cache.", + "allOf": [ + { + "$ref": "#/components/schemas/CacheMetadata" } - } + ] }, - "required": true - }, - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "environment": { + "description": "The environment we are running in.", + "allOf": [ + { + "$ref": "#/components/schemas/Environment" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "fs": { + "description": "Metadata about our file system.", + "allOf": [ + { + "$ref": "#/components/schemas/FileSystemMetadata" + } + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + "git_hash": { + "description": "The git hash of the server.", + "type": "string" + }, + "point_e": { + "description": "Metadata about our point-e instance.", + "allOf": [ + { + "$ref": "#/components/schemas/PointEMetadata" + } + ] + }, + "pubsub": { + "description": "Metadata about our pub-sub connection.", + "allOf": [ + { + "$ref": "#/components/schemas/Connection" + } + ] } }, - "summary": "Listen for GitHub webhooks.", - "tags": [ - "apps", - "hidden" + "required": [ + "cache", + "environment", + "fs", + "git_hash", + "point_e", + "pubsub" ] - } - }, - "/async/operations": { - "get": { - "description": "For async file conversion operations, this endpoint does not return the contents of converted files (`output`). To get the contents use the `/async/operations/{id}` endpoint.\nThis endpoint requires authentication by a KittyCAD employee.", - "operationId": "list_async_operations", - "parameters": [ + }, + "Method": { + "description": "The Request Method (VERB)\n\nThis type also contains constants for a number of common HTTP methods such as GET, POST, etc.\n\nCurrently includes 8 variants representing the 8 methods defined in [RFC 7230](https://tools.ietf.org/html/rfc7231#section-4.1), plus PATCH, and an Extension variant for all extensions.", + "oneOf": [ { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + "description": "The `OPTIONS` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.2.1).", + "type": "string", + "enum": [ + "OPTIONS" + ] }, { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "description": "The `GET` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", + "type": "string", + "enum": [ + "GET" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } + "description": "The `POST` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", + "type": "string", + "enum": [ + "POST" + ] }, { - "description": "The status to filter by.", - "in": "query", - "name": "status", - "schema": { - "$ref": "#/components/schemas/ApiCallStatus" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AsyncApiCallResultsPage" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "The `PUT` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.1).", + "type": "string", + "enum": [ + "PUT" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "The `DELETE` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.5).", + "type": "string", + "enum": [ + "DELETE" + ] + }, + { + "description": "The `HEAD` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.2).", + "type": "string", + "enum": [ + "HEAD" + ] + }, + { + "description": "The `TRACE` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3).", + "type": "string", + "enum": [ + "TRACE" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List async operations.", - "tags": [ - "api-calls", - "hidden" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/async/operations/{id}": { - "get": { - "description": "Get the status and output of an async operation.\nThis endpoint requires authentication by any KittyCAD user. It returns details of the requested async operation for the user.\nIf the user is not authenticated to view the specified async operation, then it is not returned.\nOnly KittyCAD employees with the proper access can view async operations for other users.", - "operationId": "get_async_operation", - "parameters": [ { - "description": "The ID of the async operation.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } + "description": "The `CONNECT` method as defined in [RFC 7231](https://tools.ietf.org/html/rfc7231#section-4.3.6).", + "type": "string", + "enum": [ + "CONNECT" + ] + }, + { + "description": "The `PATCH` method as defined in [RFC 5789](https://tools.ietf.org/html/rfc5789).", + "type": "string", + "enum": [ + "PATCH" + ] + }, + { + "description": "A catch all.", + "type": "string", + "enum": [ + "EXTENSION" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AsyncApiCallOutput" - } + ] + }, + "ModelingCmd": { + "description": "Commands that the KittyCAD engine can execute.", + "oneOf": [ + { + "description": "Start a path.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "start_path" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "type" + ] + }, + { + "description": "Move the path's \"pen\".", + "type": "object", + "properties": { + "path": { + "description": "The ID of the command which created the path.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmdId" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "to": { + "description": "Where the path's pen should be.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "move_path_pen" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "path", + "to", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get an async operation.", - "tags": [ - "api-calls" - ] - } - }, - "/auth/email": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_auth_email", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Extend a path by adding a new segment which starts at the path's \"pen\". If no \"pen\" location has been set before (via `MovePen`), then the pen is at the origin.", + "type": "object", + "properties": { + "path": { + "description": "The ID of the command which created the path.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmdId" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "segment": { + "description": "Segment to append to the path. This segment will implicitly begin at the current \"pen\" location.", + "allOf": [ + { + "$ref": "#/components/schemas/PathSegment" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "extend_path" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "path", + "segment", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "operationId": "auth_email", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/EmailAuthenticationForm" + { + "description": "Extrude a 2D solid.", + "type": "object", + "properties": { + "cap": { + "description": "Whether to cap the extrusion with a face, or not. If true, the resulting solid will be closed on all sides, like a dice. If false, it will be open on one side, like a drinking glass.", + "type": "boolean" + }, + "distance": { + "description": "How far off the plane to extrude", + "type": "number", + "format": "double" + }, + "target": { + "description": "Which sketch to extrude. Must be a closed 2D solid.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmdId" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "extrude" + ] } - } + }, + "required": [ + "cap", + "distance", + "target", + "type" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/VerificationToken" - } + { + "description": "Closes a path, converting it to a 2D solid.", + "type": "object", + "properties": { + "path_id": { + "description": "Which path to close.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "close_path" + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "path_id", + "type" + ] + }, + { + "description": "Camera drag started.", + "type": "object", + "properties": { + "interaction": { + "description": "The type of camera drag interaction.", + "allOf": [ + { + "$ref": "#/components/schemas/CameraDragInteractionType" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "camera_drag_start" + ] + }, + "window": { + "description": "The initial mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "interaction", + "type", + "window" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Create an email verification request for a user.", - "tags": [ - "hidden" - ] - } - }, - "/auth/email/callback": { - "get": { - "operationId": "auth_email_callback", - "parameters": [ { - "description": "The URL to redirect back to after we have authenticated.", - "in": "query", - "name": "callback_url", - "schema": { - "format": "uri", - "nullable": true, - "type": "string" - } + "description": "Camera drag continued.", + "type": "object", + "properties": { + "interaction": { + "description": "The type of camera drag interaction.", + "allOf": [ + { + "$ref": "#/components/schemas/CameraDragInteractionType" + } + ] + }, + "sequence": { + "nullable": true, + "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "type": { + "type": "string", + "enum": [ + "camera_drag_move" + ] + }, + "window": { + "description": "The current mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + }, + "required": [ + "interaction", + "type", + "window" + ] }, { - "description": "The user's email.", - "in": "query", - "name": "email", - "required": true, - "schema": { - "format": "email", - "type": "string" - } + "description": "Camera drag ended.", + "type": "object", + "properties": { + "interaction": { + "description": "The type of camera drag interaction.", + "allOf": [ + { + "$ref": "#/components/schemas/CameraDragInteractionType" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "camera_drag_end" + ] + }, + "window": { + "description": "The final mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + }, + "required": [ + "interaction", + "type", + "window" + ] }, { - "description": "The verification token.", - "in": "query", - "name": "token", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "302": { - "description": "Temporary Redirect", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "description": "Change what the default camera is looking at.", + "type": "object", + "properties": { + "center": { + "description": "What the camera is looking at. Center of the camera's field of vision", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "default_camera_look_at" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "up": { + "description": "Which way is \"up\", from the camera's point of view.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Set-Cookie": { - "description": "Set-Cookie header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "vantage": { + "description": "Where the camera is positioned", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] } - } + }, + "required": [ + "center", + "type", + "up", + "vantage" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Adjust zoom of the default camera.", + "type": "object", + "properties": { + "magnitude": { + "description": "Move the camera forward along the vector it's looking at, by this magnitudedefaultCameraZoom. Basically, how much should the camera move forward by.", + "type": "number", + "format": "float" + }, + "type": { + "type": "string", + "enum": [ + "default_camera_zoom" + ] + } + }, + "required": [ + "magnitude", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Listen for callbacks for email verification for users.", - "tags": [ - "hidden" - ] - } - }, - "/file/center-of-mass": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_center_of_mass", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Enable sketch mode, where users can sketch 2D geometry. Users choose a plane to sketch on.", + "type": "object", + "properties": { + "animated": { + "description": "Should we animate or snap for the camera transition?", + "type": "boolean" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "distance_to_plane": { + "description": "How far to the sketching plane?", + "type": "number", + "format": "float" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "origin": { + "description": "What's the origin of the sketching plane?", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "ortho": { + "description": "Should the camera use orthographic projection? In other words, should an object's size in the rendered image stay constant regardless of its distance from the camera.", + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "default_camera_enable_sketch_mode" + ] + }, + "x_axis": { + "description": "Which 3D axis of the scene should be the X axis of the sketching plane?", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "y_axis": { + "description": "Which 3D axis of the scene should be the Y axis of the sketching plane?", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "animated", + "distance_to_plane", + "origin", + "ortho", + "type", + "x_axis", + "y_axis" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the cartesian co-ordinate in world space measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the center of mass of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_center_of_mass", - "parameters": [ { - "description": "The output unit for the center of mass.", - "in": "query", - "name": "output_unit", - "schema": { - "$ref": "#/components/schemas/UnitLength" - } + "description": "Disable sketch mode, from the default camera.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "default_camera_disable_sketch_mode" + ] + } + }, + "required": [ + "type" + ] }, { - "description": "The format of the file.", - "in": "query", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Export the scene to a file.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to be exported. If this is empty, then all entities are exported.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } + }, + "format": { + "description": "The file format to export to.", + "allOf": [ + { + "$ref": "#/components/schemas/OutputFormat" + } + ] + }, + "source_unit": { + "description": "Select the unit interpretation of exported objects.\n\nThis is not the same as the export units. Setting export units is part of the format options.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "export" + ] } - } + }, + "required": [ + "entity_ids", + "format", + "source_unit", + "type" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileCenterOfMass" - } + { + "description": "What is this entity's parent?", + "type": "object", + "properties": { + "entity_id": { + "description": "ID of the entity being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "entity_get_parent_id" + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "entity_id", + "type" + ] + }, + { + "description": "How many children does the entity have?", + "type": "object", + "properties": { + "entity_id": { + "description": "ID of the entity being queried.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "entity_get_num_children" + ] + } + }, + "required": [ + "entity_id", + "type" + ] + }, + { + "description": "What is the UUID of this entity's n-th child?", + "type": "object", + "properties": { + "child_index": { + "description": "Index into the entity's list of children.", + "type": "integer", + "format": "uint32", + "minimum": 0 }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "entity_id": { + "description": "ID of the entity being queried.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "entity_get_child_uuid" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "child_index", + "entity_id", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get CAD file center of mass.", - "tags": [ - "file", - "beta", - "hidden" - ] - } - }, - "/file/conversion/{src_format}/{output_format}": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_conversion", - "parameters": [ { - "description": "The format the file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } + "description": "What are all UUIDs of this entity's children?", + "type": "object", + "properties": { + "entity_id": { + "description": "ID of the entity being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "entity_get_all_child_uuids" + ] + } + }, + "required": [ + "entity_id", + "type" + ] }, { - "description": "The format of the file to convert.", - "in": "path", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "description": "Enter edit mode", + "type": "object", + "properties": { + "target": { + "description": "The edit target", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "edit_mode_enter" + ] + } + }, + "required": [ + "target", + "type" + ] + }, + { + "description": "Exit edit mode", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "edit_mode_exit" + ] + } + }, + "required": [ + "type" + ] + }, + { + "description": "Modifies the selection by simulating a \"mouse click\" at the given x,y window coordinate Returns ID of whatever was selected.", + "type": "object", + "properties": { + "selected_at_window": { + "description": "Where in the window was selected", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "selection_type": { + "description": "What entity was selected?", + "allOf": [ + { + "$ref": "#/components/schemas/SceneSelectionType" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "select_with_point" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "selected_at_window", + "selection_type", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "If you wish to specify the conversion options, use the `/file/conversion` endpoint instead.\nConvert a CAD file from one format to another. If the file being converted is larger than 25MB, it will be performed asynchronously.\nIf the conversion is performed synchronously, the contents of the converted file (`output`) will be returned as a base64 encoded string.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_conversion", - "parameters": [ { - "description": "The format the file should be converted to.", - "in": "path", - "name": "output_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileExportFormat" - } + "description": "Clear the selection", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "select_clear" + ] + } + }, + "required": [ + "type" + ] }, { - "description": "The format of the file to convert.", - "in": "path", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Adds one or more entities (by UUID) to the selection.", + "type": "object", + "properties": { + "entities": { + "description": "Which entities to select", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } + }, + "type": { + "type": "string", + "enum": [ + "select_add" + ] } - } + }, + "required": [ + "entities", + "type" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileConversion" + { + "description": "Removes one or more entities (by UUID) from the selection.", + "type": "object", + "properties": { + "entities": { + "description": "Which entities to unselect", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } + }, + "type": { + "type": "string", + "enum": [ + "select_remove" + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "entities", + "type" + ] + }, + { + "description": "Replaces the current selection with these new entities (by UUID). Equivalent to doing SelectClear then SelectAdd.", + "type": "object", + "properties": { + "entities": { + "description": "Which entities to select", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "select_replace" + ] + } + }, + "required": [ + "entities", + "type" + ] + }, + { + "description": "Find all IDs of selected entities", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "select_get" + ] + } + }, + "required": [ + "type" + ] + }, + { + "description": "Changes the current highlighted entity to whichever one is at the given window coordinate. If there's no entity at this location, clears the highlight.", + "type": "object", + "properties": { + "selected_at_window": { + "description": "Coordinates of the window being clicked", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "sequence": { + "nullable": true, + "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", + "type": "integer", + "format": "uint32", + "minimum": 0 }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "highlight_set_entity" + ] } - } + }, + "required": [ + "selected_at_window", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Changes the current highlighted entity to these entities.", + "type": "object", + "properties": { + "entities": { + "description": "Highlight these entities.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } + }, + "type": { + "type": "string", + "enum": [ + "highlight_set_entities" + ] + } + }, + "required": [ + "entities", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Convert CAD file with defaults.", - "tags": [ - "file" - ] - } - }, - "/file/density": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_density", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Create a new annotation", + "type": "object", + "properties": { + "annotation_type": { + "description": "What type of annotation to create.", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationType" + } + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "clobber": { + "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", + "type": "boolean" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "options": { + "description": "What should the annotation contain?", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationOptions" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "new_annotation" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "annotation_type", + "clobber", + "options", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint assumes if you are giving a material mass in a specific mass units, we return a density in mass unit per cubic measure unit.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the density of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_density", - "parameters": [ { - "description": "The material mass.", - "in": "query", - "name": "material_mass", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "description": "Update an annotation", + "type": "object", + "properties": { + "annotation_id": { + "description": "Which annotation to update", + "type": "string", + "format": "uuid" + }, + "options": { + "description": "If any of these fields are set, they will overwrite the previous options for the annotation.", + "allOf": [ + { + "$ref": "#/components/schemas/AnnotationOptions" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "update_annotation" + ] + } + }, + "required": [ + "annotation_id", + "options", + "type" + ] }, { - "description": "The unit of the material mass.", - "in": "query", - "name": "material_mass_unit", - "schema": { - "$ref": "#/components/schemas/UnitMass" - } + "description": "Hide or show an object", + "type": "object", + "properties": { + "hidden": { + "description": "Whether or not the object should be hidden.", + "type": "boolean" + }, + "object_id": { + "description": "Which object to change", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "object_visible" + ] + } + }, + "required": [ + "hidden", + "object_id", + "type" + ] }, { - "description": "The output unit for the density.", - "in": "query", - "name": "output_unit", - "schema": { - "$ref": "#/components/schemas/UnitDensity" - } + "description": "Bring an object to the front of the scene", + "type": "object", + "properties": { + "object_id": { + "description": "Which object to change", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "object_bring_to_front" + ] + } + }, + "required": [ + "object_id", + "type" + ] }, { - "description": "The format of the file.", - "in": "query", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "What type of entity is this?", + "type": "object", + "properties": { + "entity_id": { + "description": "ID of the entity being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "get_entity_type" + ] } - } + }, + "required": [ + "entity_id", + "type" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileDensity" - } + { + "description": "Gets all faces which use the given edge.", + "type": "object", + "properties": { + "edge_id": { + "description": "Which edge you want the faces of.", + "type": "string", + "format": "uuid" + }, + "object_id": { + "description": "Which object is being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "solid3d_get_all_edge_faces" + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "edge_id", + "object_id", + "type" + ] + }, + { + "description": "Gets all edges which are opposite the given edge, across all possible faces.", + "type": "object", + "properties": { + "along_vector": { + "nullable": true, + "description": "If given, ohnly faces parallel to this vector will be considered.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "edge_id": { + "description": "Which edge you want the opposites of.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "object_id": { + "description": "Which object is being queried.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "solid3d_get_all_opposite_edges" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "edge_id", + "object_id", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get CAD file density.", - "tags": [ - "file", - "beta" - ] - } - }, - "/file/execute/{lang}": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_execution", - "parameters": [ { - "description": "The language of the code.", - "in": "path", - "name": "lang", - "required": true, - "schema": { - "$ref": "#/components/schemas/CodeLanguage" - } - } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "description": "Gets the edge opposite the given edge, along the given face.", + "type": "object", + "properties": { + "edge_id": { + "description": "Which edge you want the opposite of.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "face_id": { + "description": "Which face is used to figure out the opposite edge?", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "object_id": { + "description": "Which object is being queried.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "solid3d_get_opposite_edge" + ] } - } + }, + "required": [ + "edge_id", + "face_id", + "object_id", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Gets the next adjacent edge for the given edge, along the given face.", + "type": "object", + "properties": { + "edge_id": { + "description": "Which edge you want the opposite of.", + "type": "string", + "format": "uuid" + }, + "face_id": { + "description": "Which face is used to figure out the opposite edge?", + "type": "string", + "format": "uuid" + }, + "object_id": { + "description": "Which object is being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "solid3d_get_next_adjacent_edge" + ] + } + }, + "required": [ + "edge_id", + "face_id", + "object_id", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "operationId": "create_file_execution", - "parameters": [ { - "description": "The language of the code.", - "in": "path", - "name": "lang", - "required": true, - "schema": { - "$ref": "#/components/schemas/CodeLanguage" - } + "description": "Gets the previous adjacent edge for the given edge, along the given face.", + "type": "object", + "properties": { + "edge_id": { + "description": "Which edge you want the opposite of.", + "type": "string", + "format": "uuid" + }, + "face_id": { + "description": "Which face is used to figure out the opposite edge?", + "type": "string", + "format": "uuid" + }, + "object_id": { + "description": "Which object is being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "solid3d_get_prev_adjacent_edge" + ] + } + }, + "required": [ + "edge_id", + "face_id", + "object_id", + "type" + ] }, { - "description": "The output file we want to get the contents for (the paths are relative to where in litterbox it is being run). You can denote more than one file with a comma separated list of string paths.", - "in": "query", - "name": "output", - "schema": { - "nullable": true, - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Sends object to front or back.", + "type": "object", + "properties": { + "front": { + "description": "Bring to front = true, send to back = false.", + "type": "boolean" + }, + "object_id": { + "description": "Which object is being changed.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "send_object" + ] } - } + }, + "required": [ + "front", + "object_id", + "type" + ] }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CodeOutput" - } + { + "description": "Set opacity of the entity.", + "type": "object", + "properties": { + "entity_id": { + "description": "Which entity is being changed.", + "type": "string", + "format": "uuid" + }, + "opacity": { + "description": "How transparent should it be? 0 or lower is totally transparent. 1 or greater is totally opaque.", + "type": "number", + "format": "float" + }, + "type": { + "type": "string", + "enum": [ + "entity_set_opacity" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "entity_id", + "opacity", + "type" + ] + }, + { + "description": "Fade the entity in or out.", + "type": "object", + "properties": { + "duration_seconds": { + "description": "How many seconds the animation should take.", + "default": 0.4000000059604645, + "type": "number", + "format": "float" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "entity_id": { + "description": "Which entity is being changed.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "fade_in": { + "description": "Fade in = true, fade out = false.", + "type": "boolean" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "entity_fade" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "entity_id", + "fade_in", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Execute a KittyCAD program in a specific language.", - "tags": [ - "executor", - "hidden" - ] - } - }, - "/file/mass": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_mass", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Make a plane.", + "type": "object", + "properties": { + "clobber": { + "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", + "type": "boolean" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "hide": { + "nullable": true, + "description": "If true, the plane will be created but hidden initially.", + "type": "boolean" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "origin": { + "description": "Origin of the plane", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "size": { + "description": "What should the plane's span/extent? When rendered visually, this is both the width and height along X and Y axis respectively.", + "type": "number", + "format": "double" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "make_plane" + ] + }, + "x_axis": { + "description": "What should the plane's X axis be?", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "y_axis": { + "description": "What should the plane's Y axis be?", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint assumes if you are giving a material density in a specific mass unit per cubic measure unit, we return a mass in mass units. The same mass units as passed in the material density.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the mass of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_mass", - "parameters": [ - { - "description": "The material density.", - "in": "query", - "name": "material_density", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + }, + "required": [ + "clobber", + "origin", + "size", + "type", + "x_axis", + "y_axis" + ] }, { - "description": "The unit of the material density.", - "in": "query", - "name": "material_density_unit", - "schema": { - "$ref": "#/components/schemas/UnitDensity" - } + "description": "Set the plane's color.", + "type": "object", + "properties": { + "color": { + "description": "What color it should be.", + "allOf": [ + { + "$ref": "#/components/schemas/Color" + } + ] + }, + "plane_id": { + "description": "Which plane is being changed.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "plane_set_color" + ] + } + }, + "required": [ + "color", + "plane_id", + "type" + ] }, { - "description": "The output unit for the mass.", - "in": "query", - "name": "output_unit", - "schema": { - "$ref": "#/components/schemas/UnitMass" - } + "description": "Set the active tool.", + "type": "object", + "properties": { + "tool": { + "description": "What tool should be active.", + "allOf": [ + { + "$ref": "#/components/schemas/SceneToolType" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "set_tool" + ] + } + }, + "required": [ + "tool", + "type" + ] }, { - "description": "The format of the file.", - "in": "query", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Send a mouse move event.", + "type": "object", + "properties": { + "sequence": { + "nullable": true, + "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "type": { + "type": "string", + "enum": [ + "mouse_move" + ] + }, + "window": { + "description": "Where the mouse is", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] } - } + }, + "required": [ + "type", + "window" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileMass" - } + { + "description": "Send a mouse click event. Updates modified/selected entities.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "mouse_click" + ] + }, + "window": { + "description": "Where the mouse is", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "type", + "window" + ] + }, + { + "description": "Enable sketch mode on the given plane.", + "type": "object", + "properties": { + "animated": { + "description": "Animate the transition to sketch mode.", + "type": "boolean" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "disable_camera_with_plane": { + "nullable": true, + "description": "Disable the camera entirely for sketch mode and sketch on a plane (this would be the normal of that plane).", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "ortho": { + "description": "Use an orthographic camera.", + "type": "boolean" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "plane_id": { + "description": "Sketch on this plane.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "sketch_mode_enable" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "animated", + "ortho", + "plane_id", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get CAD file mass.", - "tags": [ - "file", - "beta" - ] - } - }, - "/file/surface-area": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_surface_area", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Disable sketch mode.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "sketch_mode_disable" + ] + } + }, + "required": [ + "type" + ] + }, + { + "description": "Get type of a given curve.", + "type": "object", + "properties": { + "curve_id": { + "description": "Which curve to query.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "curve_get_type" + ] + } + }, + "required": [ + "curve_id", + "type" + ] + }, + { + "description": "Get control points of a given curve.", + "type": "object", + "properties": { + "curve_id": { + "description": "Which curve to query.", + "type": "string", + "format": "uuid" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "curve_get_control_points" + ] } - } + }, + "required": [ + "curve_id", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Take a snapshot.", + "type": "object", + "properties": { + "format": { + "description": "What image format to return.", + "allOf": [ + { + "$ref": "#/components/schemas/ImageFormat" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "take_snapshot" + ] + } + }, + "required": [ + "format", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the square measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the surface area of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_surface_area", - "parameters": [ { - "description": "The output unit for the surface area.", - "in": "query", - "name": "output_unit", - "schema": { - "$ref": "#/components/schemas/UnitArea" - } + "description": "Add a gizmo showing the axes.", + "type": "object", + "properties": { + "clobber": { + "description": "If true, any existing drawables within the obj will be replaced (the object will be reset)", + "type": "boolean" + }, + "gizmo_mode": { + "description": "If true, axes gizmo will be placed in the corner of the screen. If false, it will be placed at the origin of the scene.", + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "make_axes_gizmo" + ] + } + }, + "required": [ + "clobber", + "gizmo_mode", + "type" + ] }, { - "description": "The format of the file.", - "in": "query", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Query the given path", + "type": "object", + "properties": { + "path_id": { + "description": "Which path to query", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "path_get_info" + ] } - } + }, + "required": [ + "path_id", + "type" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileSurfaceArea" + { + "description": "Get curves for vertices within a path", + "type": "object", + "properties": { + "path_id": { + "description": "Which path to query", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "path_get_curve_uuids_for_vertices" + ] + }, + "vertex_ids": { + "description": "IDs of the vertices for which to obtain curve ids from", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "path_id", + "type", + "vertex_ids" + ] + }, + { + "description": "Start dragging mouse.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "handle_mouse_drag_start" + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "window": { + "description": "The mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + }, + "required": [ + "type", + "window" + ] + }, + { + "description": "Continue dragging mouse.", + "type": "object", + "properties": { + "sequence": { + "nullable": true, + "description": "Logical timestamp. The client should increment this with every event in the current mouse drag. That way, if the events are being sent over an unordered channel, the API can ignore the older events.", + "type": "integer", + "format": "uint32", + "minimum": 0 }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "handle_mouse_drag_move" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "window": { + "description": "The mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "type", + "window" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get CAD file surface area.", - "tags": [ - "file", - "beta", - "hidden" - ] - } - }, - "/file/volume": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_file_volume", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Stop dragging mouse.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "handle_mouse_drag_end" + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" + "window": { + "description": "The mouse position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + }, + "required": [ + "type", + "window" + ] + }, + { + "description": "Remove scene objects.", + "type": "object", + "properties": { + "object_ids": { + "description": "Objects to remove.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" }, - "style": "simple" + "uniqueItems": true }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "remove_scene_objects" + ] } - } + }, + "required": [ + "object_ids", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Utility method. Performs both a ray cast and projection to plane-local coordinates. Returns the plane coordinates for the given window coordinates.", + "type": "object", + "properties": { + "plane_id": { + "description": "The plane you're intersecting against.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "plane_intersect_and_project" + ] + }, + "window": { + "description": "Window coordinates where the ray cast should be aimed.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + }, + "required": [ + "plane_id", + "type", + "window" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "We assume any file given to us has one consistent unit throughout. We also assume the file is at the proper scale.\nThis endpoint returns the cubic measure units.\nIn the future, we will use the units inside the file if they are given and do any conversions if necessary for the calculation. But currently, that is not supported.\nGet the volume of an object in a CAD file. If the file is larger than 25MB, it will be performed asynchronously.\nIf the operation is performed asynchronously, the `id` of the operation will be returned. You can use the `id` returned from the request to get status information about the async operation from the `/async/operations/{id}` endpoint.", - "operationId": "create_file_volume", - "parameters": [ { - "description": "The output unit for the volume.", - "in": "query", - "name": "output_unit", - "schema": { - "$ref": "#/components/schemas/UnitVolume" - } + "description": "Find the start and end of a curve.", + "type": "object", + "properties": { + "curve_id": { + "description": "ID of the curve being queried.", + "type": "string", + "format": "uuid" + }, + "type": { + "type": "string", + "enum": [ + "curve_get_end_points" + ] + } + }, + "required": [ + "curve_id", + "type" + ] }, { - "description": "The format of the file.", - "in": "query", - "name": "src_format", - "required": true, - "schema": { - "$ref": "#/components/schemas/FileImportFormat" - } - } - ], - "requestBody": { - "content": { - "application/octet-stream": { - "schema": { - "format": "binary", - "type": "string" + "description": "Reconfigure the stream.", + "type": "object", + "properties": { + "fps": { + "description": "Frames per second.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "height": { + "description": "Height of the stream.", + "type": "integer", + "format": "uint32", + "minimum": 0 + }, + "type": { + "type": "string", + "enum": [ + "reconfigure_stream" + ] + }, + "width": { + "description": "Width of the stream.", + "type": "integer", + "format": "uint32", + "minimum": 0 } - } + }, + "required": [ + "fps", + "height", + "type", + "width" + ] }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FileVolume" + { + "description": "Import files to the current model.", + "type": "object", + "properties": { + "files": { + "description": "Files to import", + "type": "array", + "items": { + "$ref": "#/components/schemas/ImportFile" } + }, + "type": { + "type": "string", + "enum": [ + "import_files" + ] } }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "files", + "type" + ] + }, + { + "description": "Get the mass of entities in the scene or the default scene.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to get the mass of. If this is empty, then the default scene is included in the mass.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "material_density": { + "description": "The material density.", + "type": "number", + "format": "double" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "material_density_unit": { + "description": "The material density unit.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitDensity" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get CAD file volume.", - "tags": [ - "file", - "beta", - "hidden" - ] - } - }, - "/hidden/ws/modeling": { - "options": { - "operationId": "hidden_ws_modeling_types", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/WebSocketRequest" + "output_unit": { + "description": "The output unit for the mass.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" + } + ] + }, + "source_unit": { + "description": "Select the unit interpretation of distances in the scene.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "mass" + ] } - } - }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/WebSocketResponse" + }, + "required": [ + "entity_ids", + "material_density", + "material_density_unit", + "output_unit", + "source_unit", + "type" + ] + }, + { + "description": "Get the density of entities in the scene or the default scene.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to get the density of. If this is empty, then the default scene is included in the density.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "material_mass": { + "description": "The material mass.", + "type": "number", + "format": "double" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "material_mass_unit": { + "description": "The material mass unit.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "output_unit": { + "description": "The output unit for the density.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitDensity" + } + ] + }, + "source_unit": { + "description": "Select the unit interpretation of distances in the scene.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "density" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "entity_ids", + "material_mass", + "material_mass_unit", + "output_unit", + "source_unit", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Hidden endpoint for defining the modeling websocket types.", - "tags": [ - "hidden" - ] - } - }, - "/logout": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_logout", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Get the volume of entities in the scene or the default scene.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to get the volume of. If this is empty, then the default scene is included in the volume.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "output_unit": { + "description": "The output unit for the volume.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "source_unit": { + "description": "Select the unit interpretation of distances in the scene.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "volume" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "entity_ids", + "output_unit", + "source_unit", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "This is used in logout scenarios.", - "operationId": "logout", - "responses": { - "204": { - "description": "resource updated", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Get the center of mass of entities in the scene or the default scene.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to get the center of mass of. If this is empty, then the default scene is included in the center of mass.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "output_unit": { + "description": "The output unit for the center of mass.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "source_unit": { + "description": "Select the unit interpretation of distances in the scene.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] }, - "Set-Cookie": { - "description": "Set-Cookie header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "center_of_mass" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "entity_ids", + "output_unit", + "source_unit", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "This endpoint removes the session cookie for a user.", - "tags": [ - "hidden" - ] - } - }, - "/oauth2/device/auth": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_device_auth_request", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + { + "description": "Get the surface area of entities in the scene or the default scene.", + "type": "object", + "properties": { + "entity_ids": { + "description": "IDs of the entities to get the surface area of. If this is empty, then the default scene is included in the surface area.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "output_unit": { + "description": "The output unit for the surface area.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitArea" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "source_unit": { + "description": "Select the unit interpretation of distances in the scene.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "This endpoint is designed to be accessed from an *unauthenticated* API client. It generates and records a `device_code` and `user_code` which must be verified and confirmed prior to a token being granted.", - "operationId": "device_auth_request", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "$ref": "#/components/schemas/DeviceAuthRequestForm" + "type": { + "type": "string", + "enum": [ + "surface_area" + ] } - } + }, + "required": [ + "entity_ids", + "output_unit", + "source_unit", + "type" + ] }, - "required": true - }, - "responses": { - "default": { - "content": { - "*/*": { - "schema": {} + { + "description": "Get the plane of the sketch mode. This is useful for getting the normal of the plane after a user selects a plane.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "get_sketch_mode_plane" + ] } }, - "description": "" + "required": [ + "type" + ] } - }, - "summary": "Start an OAuth 2.0 Device Authorization Grant.", - "tags": [ - "oauth2", - "hidden" ] - } - }, - "/oauth2/device/confirm": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_device_auth_confirm", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + }, + "ModelingCmdId": { + "description": "All commands have unique IDs. These should be randomly generated.", + "type": "string", + "format": "uuid" + }, + "MouseClick": { + "description": "The response from the `MouseClick` command.", + "type": "object", + "properties": { + "entities_modified": { + "description": "Entities that are modified.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + "entities_selected": { + "description": "Entities that are selected.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" + } } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "entities_modified", + "entities_selected" ] }, - "post": { - "description": "This endpoint is designed to be accessed by the user agent (browser), not the client requesting the token. So we do not actually return the token here; it will be returned in response to the poll on `/oauth2/device/token`.", - "operationId": "device_auth_confirm", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeviceAuthVerifyParams" - } - } + "NewAddress": { + "description": "The struct that is used to create a new record. This is automatically generated and has all the same fields as the main struct only it is missing the `id`.", + "type": "object", + "properties": { + "city": { + "description": "The city component.", + "type": "string" }, - "required": true - }, - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "country": { + "description": "The country component. This is a two-letter ISO country code.", + "allOf": [ + { + "$ref": "#/components/schemas/CountryCode" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "state": { + "description": "The state component.", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Confirm an OAuth 2.0 Device Authorization Grant.", - "tags": [ - "oauth2", - "hidden" - ] - } - }, - "/oauth2/device/token": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_device_access_token", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "street1": { + "description": "The first street component.", + "type": "string" + }, + "street2": { + "description": "The second street component.", + "type": "string" }, - "4XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID that this address belongs to.", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" + "zip": { + "description": "The zip component.", + "type": "string" } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "country" ] }, - "post": { - "description": "This endpoint should be polled by the client until the user code is verified and the grant is confirmed.", - "operationId": "device_access_token", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "$ref": "#/components/schemas/DeviceAccessTokenRequestForm" - } - } + "OAuth2ClientInfo": { + "description": "Information about an OAuth 2.0 client.", + "type": "object", + "properties": { + "csrf_token": { + "description": "Value used for [CSRF](https://tools.ietf.org/html/rfc6749#section-10.12) protection via the `state` parameter.", + "type": "string" }, - "required": true - }, - "responses": { - "default": { - "content": { - "*/*": { - "schema": {} - } - }, - "description": "" + "pkce_code_verifier": { + "nullable": true, + "description": "Code Verifier used for [PKCE]((https://tools.ietf.org/html/rfc7636)) protection via the `code_verifier` parameter. The value must have a minimum length of 43 characters and a maximum length of 128 characters. Each character must be ASCII alphanumeric or one of the characters \"-\" / \".\" / \"_\" / \"~\".", + "type": "string" + }, + "url": { + "description": "The URL for consent.", + "type": "string" } - }, - "summary": "Request a device access token.", - "tags": [ - "oauth2", - "hidden" - ] - } - }, - "/oauth2/device/verify": { - "get": { - "description": "This endpoint should be accessed in a full user agent (e.g., a browser). If the user is not logged in, we redirect them to the login page and use the `callback_url` parameter to get them to the UI verification form upon logging in. If they are logged in, we redirect them to the UI verification form on the website.", - "operationId": "device_auth_verify", - "parameters": [ + } + }, + "OAuth2GrantType": { + "description": "An OAuth 2.0 Grant Type. These are documented here: .", + "oneOf": [ { - "description": "The user code.", - "in": "query", - "name": "user_code", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "302": { - "description": "Temporary Redirect", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" + "description": "An OAuth 2.0 Device Authorization Grant.", + "type": "string", + "enum": [ + "urn:ietf:params:oauth:grant-type:device_code" + ] } - }, - "summary": "Verify an OAuth 2.0 Device Authorization Grant.", - "tags": [ - "oauth2", - "hidden" ] - } - }, - "/oauth2/provider/{provider}/callback": { - "get": { - "operationId": "oauth2_provider_callback", - "parameters": [ + }, + "OkModelingCmdResponse": { + "description": "A successful response from a modeling command. This can be one of several types of responses, depending on the command.", + "oneOf": [ { - "description": "The provider.", - "in": "path", - "name": "provider", - "required": true, - "schema": { - "$ref": "#/components/schemas/AccountProvider" - } + "description": "An empty response, used for any command that does not explicitly have a response defined here.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "empty" + ] + } + }, + "required": [ + "type" + ] }, { - "description": "The authorization code.", - "in": "query", - "name": "code", - "schema": { - "type": "string" - } + "description": "The response from the `Export` command. When this is being performed over a websocket, this is sent as binary not JSON. The binary data can be deserialized as `bincode` into a `Vec`.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Export" + }, + "type": { + "type": "string", + "enum": [ + "export" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The state that we had passed in through the user consent URL.", - "in": "query", - "name": "state", - "schema": { - "type": "string" - } - } - ], - "responses": { - "302": { - "description": "Temporary Redirect", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "description": "The response from the `SelectWithPoint` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/SelectWithPoint" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "select_with_point" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `HighlightSetEntity` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/HighlightSetEntity" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "highlight_set_entity" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `EntityGetChildUuid` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/EntityGetChildUuid" }, - "Set-Cookie": { - "description": "Set-Cookie header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "entity_get_child_uuid" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `EntityGetNumChildren` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/EntityGetNumChildren" + }, + "type": { + "type": "string", + "enum": [ + "entity_get_num_children" + ] } - } + }, + "required": [ + "data", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "The response from the `EntityGetParentId` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/EntityGetParentId" + }, + "type": { + "type": "string", + "enum": [ + "entity_get_parent_id" + ] + } + }, + "required": [ + "data", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Listen for callbacks for the OAuth 2.0 provider.", - "tags": [ - "oauth2", - "hidden" - ] - } - }, - "/oauth2/provider/{provider}/consent": { - "get": { - "operationId": "oauth2_provider_consent", - "parameters": [ { - "description": "The provider.", - "in": "path", - "name": "provider", - "required": true, - "schema": { - "$ref": "#/components/schemas/AccountProvider" - } + "description": "The response from the `EntityGetAllChildUuids` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/EntityGetAllChildUuids" + }, + "type": { + "type": "string", + "enum": [ + "entity_get_all_child_uuids" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The URL to redirect back to after we have authenticated.", - "in": "query", - "name": "callback_url", - "schema": { - "nullable": true, - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/OAuth2ClientInfo" - } + "description": "The response from the `SelectGet` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/SelectGet" + }, + "type": { + "type": "string", + "enum": [ + "select_get" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `GetEntityType` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/GetEntityType" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "get_entity_type" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Solid3dGetAllEdgeFaces` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Solid3dGetAllEdgeFaces" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "solid3d_get_all_edge_faces" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Solid3dGetAllOppositeEdges` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Solid3dGetAllOppositeEdges" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "solid3d_get_all_opposite_edges" + ] } - } + }, + "required": [ + "data", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "The response from the `Solid3dGetOppositeEdge` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Solid3dGetOppositeEdge" + }, + "type": { + "type": "string", + "enum": [ + "solid3d_get_opposite_edge" + ] + } + }, + "required": [ + "data", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get the consent URL and other information for the OAuth 2.0 provider.", - "tags": [ - "oauth2", - "hidden" - ] - } - }, - "/openai/openapi.json": { - "get": { - "description": "This is the same as the OpenAPI schema, BUT it has some modifications to make it compatible with OpenAI. For example, descriptions must be < 300 chars.", - "operationId": "get_openai_schema", - "responses": { - "200": { - "content": { - "application/json": { - "schema": {} + { + "description": "The response from the `Solid3dGetPrevAdjacentEdge` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Solid3dGetPrevAdjacentEdge" + }, + "type": { + "type": "string", + "enum": [ + "solid3d_get_prev_adjacent_edge" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Solid3dGetNextAdjacentEdge` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Solid3dGetNextAdjacentEdge" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "solid3d_get_next_adjacent_edge" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `MouseClick` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/MouseClick" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "mouse_click" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `CurveGetType` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/CurveGetType" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "curve_get_type" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "data", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get AI plugin OpenAPI schema.", - "tags": [ - "meta", - "hidden" - ] - } - }, - "/ping": { - "get": { - "operationId": "ping", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Pong" - } + { + "description": "The response from the `CurveGetControlPoints` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/CurveGetControlPoints" + }, + "type": { + "type": "string", + "enum": [ + "curve_get_control_points" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Take Snapshot` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/TakeSnapshot" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "take_snapshot" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Path Get Info` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/PathGetInfo" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "path_get_info" + ] } - } + }, + "required": [ + "data", + "type" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "The response from the `Path Get Curve UUIDs for Vertices` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/PathGetCurveUuidsForVertices" + }, + "type": { + "type": "string", + "enum": [ + "path_get_curve_uuids_for_vertices" + ] + } + }, + "required": [ + "data", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Return pong.", - "tags": [ - "meta" - ] - } - }, - "/unit/conversion/angle/{input_unit}/{output_unit}": { - "get": { - "description": "Convert an angle unit value to another angle unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_angle_unit_conversion", - "parameters": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitAngle" - } + "description": "The response from the `PlaneIntersectAndProject` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/PlaneIntersectAndProject" + }, + "type": { + "type": "string", + "enum": [ + "plane_intersect_and_project" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitAngle" - } + "description": "The response from the `CurveGetEndPoints` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/CurveGetEndPoints" + }, + "type": { + "type": "string", + "enum": [ + "curve_get_end_points" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitAngleConversion" - } + "description": "The response from the `ImportFiles` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/ImportFiles" + }, + "type": { + "type": "string", + "enum": [ + "import_files" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Mass` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Mass" }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "mass" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Volume` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Volume" }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "volume" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The response from the `Density` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/Density" }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "density" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "data", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Convert angle units.", - "tags": [ - "unit" - ] - } - }, - "/unit/conversion/area/{input_unit}/{output_unit}": { - "get": { - "description": "Convert an area unit value to another area unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_area_unit_conversion", - "parameters": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitArea" - } + "description": "The response from the `SurfaceArea` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/SurfaceArea" + }, + "type": { + "type": "string", + "enum": [ + "surface_area" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitArea" - } + "description": "The response from the `CenterOfMass` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/CenterOfMass" + }, + "type": { + "type": "string", + "enum": [ + "center_of_mass" + ] + } + }, + "required": [ + "data", + "type" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "description": "The response from the `GetSketchModePlane` command.", + "type": "object", + "properties": { + "data": { + "$ref": "#/components/schemas/GetSketchModePlane" + }, + "type": { + "type": "string", + "enum": [ + "get_sketch_mode_plane" + ] + } + }, + "required": [ + "data", + "type" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitAreaConversion" - } + ] + }, + "OkWebSocketResponseData": { + "description": "The websocket messages this server sends.", + "oneOf": [ + { + "description": "Information about the ICE servers.", + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "ice_servers": { + "description": "Information about the ICE servers.", + "type": "array", + "items": { + "$ref": "#/components/schemas/IceServer" + } + } + }, + "required": [ + "ice_servers" + ] + }, + "type": { + "type": "string", + "enum": [ + "ice_server_info" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" + "required": [ + "data", + "type" + ] + }, + { + "description": "The trickle ICE candidate response.", + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "candidate": { + "description": "Information about the ICE candidate.", + "allOf": [ + { + "$ref": "#/components/schemas/RtcIceCandidateInit" + } + ] + } }, - "style": "simple" + "required": [ + "candidate" + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "trickle_ice" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The SDP answer response.", + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "answer": { + "description": "The session description.", + "allOf": [ + { + "$ref": "#/components/schemas/RtcSessionDescription" + } + ] + } }, - "style": "simple" + "required": [ + "answer" + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "sdp_answer" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The modeling command response.", + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "modeling_response": { + "description": "The result of the command.", + "allOf": [ + { + "$ref": "#/components/schemas/OkModelingCmdResponse" + } + ] + } }, - "style": "simple" + "required": [ + "modeling_response" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "modeling" + ] + } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "The exported files.", + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "files": { + "description": "The exported files", + "type": "array", + "items": { + "$ref": "#/components/schemas/RawFile" + } + } }, - "style": "simple" + "required": [ + "files" + ] + }, + "type": { + "type": "string", + "enum": [ + "export" + ] } - } + }, + "required": [ + "data", + "type" + ] + }, + { + "description": "Request a collection of metrics, to include WebRTC.", + "type": "object", + "properties": { + "data": { + "type": "object" + }, + "type": { + "type": "string", + "enum": [ + "metrics_request" + ] + } + }, + "required": [ + "data", + "type" + ] + } + ] + }, + "Onboarding": { + "description": "Onboarding details", + "type": "object", + "properties": { + "first_call_from_their_machine_date": { + "description": "When the user first called an endpoint from their machine (i.e. not a litterbox execution)", + "type": "string" }, - "4XX": { - "$ref": "#/components/responses/Error" + "first_litterbox_execute_date": { + "description": "When the user first used the litterbox", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" + "first_token_date": { + "description": "When the user created their first token", + "type": "string" } - }, - "summary": "Convert area units.", - "tags": [ - "unit" - ] - } - }, - "/unit/conversion/current/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a current unit value to another current unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_current_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitCurrent" - } - }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitCurrent" - } + } + }, + "OutputFile": { + "description": "Output file contents.", + "type": "object", + "properties": { + "contents": { + "nullable": true, + "description": "The contents of the file. This is base64 encoded so we can ensure it is UTF-8 for JSON.", + "type": "string" }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "name": { + "description": "The name of the file.", + "default": "", + "type": "string" } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitCurrentConversion" - } + } + }, + "OutputFormat": { + "description": "Output format specifier.", + "oneOf": [ + { + "description": "Autodesk Filmbox (FBX) format.", + "type": "object", + "properties": { + "storage": { + "description": "Specifies which kind of FBX will be exported.", + "allOf": [ + { + "$ref": "#/components/schemas/FbxStorage" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "fbx" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "storage", + "type" + ] + }, + { + "description": "glTF 2.0. We refer to this as glTF since that is how our customers refer to it, although by default it will be in binary format and thus technically (glb). If you prefer ascii output, you can set that option for the export.", + "type": "object", + "properties": { + "presentation": { + "description": "Specifies how the JSON will be presented.", + "allOf": [ + { + "$ref": "#/components/schemas/GltfPresentation" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "storage": { + "description": "Specifies which kind of glTF 2.0 will be exported.", + "allOf": [ + { + "$ref": "#/components/schemas/GltfStorage" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "gltf" + ] } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + }, + "required": [ + "presentation", + "storage", + "type" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Convert current units.", - "tags": [ - "unit" - ] - } - }, - "/unit/conversion/energy/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a energy unit value to another energy unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_energy_unit_conversion", - "parameters": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitEnergy" - } + "description": "Wavefront OBJ format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "obj" + ] + }, + "units": { + "description": "Export length unit.\n\nDefaults to meters.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + } + }, + "required": [ + "coords", + "type", + "units" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitEnergy" - } + "description": "The PLY Polygon File Format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] + }, + "storage": { + "description": "The storage for the output PLY file.", + "allOf": [ + { + "$ref": "#/components/schemas/PlyStorage" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "ply" + ] + } + }, + "required": [ + "coords", + "storage", + "type" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitEnergyConversion" - } + "description": "ISO 10303-21 (STEP) format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "step" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "coords", + "type" + ] + }, + { + "description": "*ST**ereo**L**ithography format.", + "type": "object", + "properties": { + "coords": { + "description": "Co-ordinate system of output data.\n\nDefaults to the [KittyCAD co-ordinate system].\n\n[KittyCAD co-ordinate system]: ../coord/constant.KITTYCAD.html", + "allOf": [ + { + "$ref": "#/components/schemas/System" + } + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "storage": { + "description": "Export storage.", + "allOf": [ + { + "$ref": "#/components/schemas/StlStorage" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "stl" + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "units": { + "description": "Export length unit.\n\nDefaults to meters.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] } + }, + "required": [ + "coords", + "storage", + "type", + "units" + ] + } + ] + }, + "PathCommand": { + "description": "The path component command type (within a Path)", + "type": "string", + "enum": [ + "move_to", + "line_to", + "bez_curve_to", + "nurbs_curve_to", + "add_arc" + ] + }, + "PathGetCurveUuidsForVertices": { + "description": "The response from the `PathGetCurveUuidsForVertices` command.", + "type": "object", + "properties": { + "curve_ids": { + "description": "The UUIDs of the curve entities.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" } }, - "summary": "Convert energy units.", - "tags": [ - "unit" + "required": [ + "curve_ids" ] - } - }, - "/unit/conversion/force/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a force unit value to another force unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_force_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitForce" + }, + "PathGetInfo": { + "description": "The response from the `PathGetInfo` command.", + "type": "object", + "properties": { + "segments": { + "description": "All segments in the path, in the order they were added.", + "type": "array", + "items": { + "$ref": "#/components/schemas/PathSegmentInfo" } + } + }, + "required": [ + "segments" + ] + }, + "PathSegment": { + "description": "A segment of a path. Paths are composed of many segments.", + "oneOf": [ + { + "description": "A straight line segment. Goes from the current path \"pen\" to the given endpoint.", + "type": "object", + "properties": { + "end": { + "description": "End point of the line.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "relative": { + "description": "Whether or not this line is a relative offset", + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "line" + ] + } + }, + "required": [ + "end", + "relative", + "type" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitForce" - } + "description": "A circular arc segment.", + "type": "object", + "properties": { + "angle_end": { + "description": "Start of the arc along circle's perimeter.", + "type": "number", + "format": "double" + }, + "angle_start": { + "description": "Start of the arc along circle's perimeter.", + "type": "number", + "format": "double" + }, + "center": { + "description": "Center of the circle", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + }, + "radius": { + "description": "Radius of the circle", + "type": "number", + "format": "double" + }, + "relative": { + "description": "Whether or not this arc is a relative offset", + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "arc" + ] + } + }, + "required": [ + "angle_end", + "angle_start", + "center", + "radius", + "relative", + "type" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitForceConversion" - } + "description": "A cubic bezier curve segment. Start at the end of the current line, go through control point 1 and 2, then end at a given point.", + "type": "object", + "properties": { + "control1": { + "description": "First control point.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "control2": { + "description": "Second control point.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "end": { + "description": "Final control point.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] + }, + "relative": { + "description": "Whether or not this bezier is a relative offset", + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "bezier" + ] } }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "required": [ + "control1", + "control2", + "end", + "relative", + "type" + ] + }, + { + "description": "Adds a tangent arc from current pen position with the given radius and angle.", + "type": "object", + "properties": { + "offset": { + "description": "Offset of the arc.", + "allOf": [ + { + "$ref": "#/components/schemas/Angle" + } + ] }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "radius": { + "description": "Radius of the arc. Not to be confused with Raiders of the Lost Ark.", + "type": "number", + "format": "double" + }, + "type": { + "type": "string", + "enum": [ + "tangential_arc" + ] + } + }, + "required": [ + "offset", + "radius", + "type" + ] + }, + { + "description": "Adds a tangent arc from current pen position to the new position.", + "type": "object", + "properties": { + "angle_snap_increment": { + "nullable": true, + "description": "0 will be interpreted as none/null.", + "allOf": [ + { + "$ref": "#/components/schemas/Angle" + } + ] }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "to": { + "description": "Where the arc should end. Must lie in the same plane as the current path pen position. Must not be colinear with current path pen position.", + "allOf": [ + { + "$ref": "#/components/schemas/Point3d" + } + ] }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "type": "string", + "enum": [ + "tangential_arc_to" + ] } - } + }, + "required": [ + "to", + "type" + ] + } + ] + }, + "PathSegmentInfo": { + "description": "Info about a path segment", + "type": "object", + "properties": { + "command": { + "description": "What is the path segment?", + "allOf": [ + { + "$ref": "#/components/schemas/PathCommand" + } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "command_id": { + "nullable": true, + "description": "Which command created this path? This field is absent if the path command is not actually creating a path segment, e.g. moving the pen doesn't create a path segment.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmdId" + } + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + "relative": { + "description": "Whether or not this segment is a relative offset", + "type": "boolean" } }, - "summary": "Convert force units.", - "tags": [ - "unit" + "required": [ + "command", + "relative" ] - } - }, - "/unit/conversion/frequency/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a frequency unit value to another frequency unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_frequency_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitFrequency" - } - }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitFrequency" - } - }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + }, + "PaymentIntent": { + "description": "A payment intent response.", + "type": "object", + "properties": { + "client_secret": { + "description": "The client secret is used for client-side retrieval using a publishable key. The client secret can be used to complete payment setup from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.", + "type": "string" } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitFrequencyConversion" - } + }, + "required": [ + "client_secret" + ] + }, + "PaymentMethod": { + "description": "A payment method.", + "type": "object", + "properties": { + "billing_info": { + "description": "The billing info for the payment method.", + "allOf": [ + { + "$ref": "#/components/schemas/BillingInfo" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "card": { + "nullable": true, + "description": "The card, if it is one. For our purposes, this is the only type of payment method that we support.", + "allOf": [ + { + "$ref": "#/components/schemas/CardDetails" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "created_at": { + "description": "Time at which the object was created.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Convert frequency units.", - "tags": [ - "unit" - ] - } - }, - "/unit/conversion/length/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a length unit value to another length unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_length_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitLength" - } + "id": { + "description": "Unique identifier for the object.", + "type": "string" }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitLength" + "metadata": { + "description": "Set of key-value pairs.", + "default": {}, + "type": "object", + "additionalProperties": { + "type": "string" } }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitLengthConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "type": { + "description": "The type of payment method.", + "allOf": [ + { + "$ref": "#/components/schemas/PaymentMethodType" } - } + ] + } + }, + "required": [ + "billing_info", + "created_at", + "type" + ] + }, + "PaymentMethodCardChecks": { + "description": "Card checks.", + "type": "object", + "properties": { + "address_line1_check": { + "description": "If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "type": "string" }, - "4XX": { - "$ref": "#/components/responses/Error" + "address_postal_code_check": { + "description": "If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" + "cvc_check": { + "description": "If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.", + "type": "string" + } + } + }, + "PaymentMethodType": { + "description": "An enum representing the possible values of an `PaymentMethod`'s `type` field.", + "oneOf": [ + { + "description": "A card payment method.", + "type": "string", + "enum": [ + "card" + ] } - }, - "summary": "Convert length units.", - "tags": [ - "unit" ] - } - }, - "/unit/conversion/mass/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a mass unit value to another mass unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_mass_unit_conversion", - "parameters": [ + }, + "PlaneIntersectAndProject": { + "description": "Corresponding coordinates of given window coordinates, intersected on given plane.", + "type": "object", + "properties": { + "plane_coordinates": { + "nullable": true, + "description": "Corresponding coordinates of given window coordinates, intersected on given plane.", + "allOf": [ + { + "$ref": "#/components/schemas/Point2d" + } + ] + } + } + }, + "PlyStorage": { + "description": "The storage for the output PLY file.", + "oneOf": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitMass" - } + "description": "Write numbers in their ascii representation (e.g. -13, 6.28, etc.). Properties are separated by spaces and elements are separated by line breaks.", + "type": "string", + "enum": [ + "ascii" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitMass" - } + "description": "Encode payload as binary using little endian.", + "type": "string", + "enum": [ + "binary_little_endian" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "description": "Encode payload as binary using big endian.", + "type": "string", + "enum": [ + "binary_big_endian" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitMassConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + ] + }, + "Point2d": { + "description": "A point in 2D space", + "type": "object", + "properties": { + "x": { + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "y": { + "type": "number", + "format": "double" } }, - "summary": "Convert mass units.", - "tags": [ - "unit" + "required": [ + "x", + "y" ] - } - }, - "/unit/conversion/power/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a power unit value to another power unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_power_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitPower" - } + }, + "Point3d": { + "description": "A point in 3D space", + "type": "object", + "properties": { + "x": { + "type": "number", + "format": "float" }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitPower" - } + "y": { + "type": "number", + "format": "float" }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "z": { + "type": "number", + "format": "float" } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitPowerConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + }, + "required": [ + "x", + "y", + "z" + ] + }, + "PointEMetadata": { + "description": "Metadata about our point-e instance.\n\nThis is mostly used for internal purposes and debugging.", + "type": "object", + "properties": { + "ok": { + "description": "If the point-e service returned an ok response from ping.", + "type": "boolean" + } + }, + "required": [ + "ok" + ] + }, + "Pong": { + "description": "The response from the `/ping` endpoint.", + "type": "object", + "properties": { + "message": { + "description": "The pong response.", + "type": "string" + } + }, + "required": [ + "message" + ] + }, + "RawFile": { + "description": "A raw file with unencoded contents to be passed over binary websockets.", + "type": "object", + "properties": { + "contents": { + "description": "The contents of the file.", + "type": "array", + "items": { + "type": "integer", + "format": "uint8", + "minimum": 0 } }, - "4XX": { - "$ref": "#/components/responses/Error" + "name": { + "description": "The name of the file.", + "type": "string" + } + }, + "required": [ + "contents", + "name" + ] + }, + "RtcIceCandidateInit": { + "description": "ICECandidateInit is used to serialize ice candidates", + "type": "object", + "properties": { + "candidate": { + "description": "The candidate string associated with the object.", + "type": "string" }, - "5XX": { - "$ref": "#/components/responses/Error" + "sdpMLineIndex": { + "nullable": true, + "description": "The index (starting at zero) of the m-line in the SDP this candidate is associated with.", + "type": "integer", + "format": "uint16", + "minimum": 0 + }, + "sdpMid": { + "nullable": true, + "description": "The identifier of the \"media stream identification\" as defined in [RFC 8841](https://tools.ietf.org/html/rfc8841).", + "type": "string" + }, + "usernameFragment": { + "nullable": true, + "description": "The username fragment (as defined in [RFC 8445](https://tools.ietf.org/html/rfc8445#section-5.2.1)) associated with the object.", + "type": "string" } }, - "summary": "Convert power units.", - "tags": [ - "unit" + "required": [ + "candidate" ] - } - }, - "/unit/conversion/pressure/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a pressure unit value to another pressure unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_pressure_unit_conversion", - "parameters": [ + }, + "RtcSdpType": { + "description": "SDPType describes the type of an SessionDescription.", + "oneOf": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitPressure" - } + "description": "Unspecified indicates that the type is unspecified.", + "type": "string", + "enum": [ + "unspecified" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitPressure" - } + "description": "indicates that a description MUST be treated as an SDP offer.", + "type": "string", + "enum": [ + "offer" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitPressureConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "indicates that a description MUST be treated as an SDP answer, but not a final answer. A description used as an SDP pranswer may be applied as a response to an SDP offer, or an update to a previously sent SDP pranswer.", + "type": "string", + "enum": [ + "pranswer" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "indicates that a description MUST be treated as an SDP final answer, and the offer-answer exchange MUST be considered complete. A description used as an SDP answer may be applied as a response to an SDP offer or as an update to a previously sent SDP pranswer.", + "type": "string", + "enum": [ + "answer" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "indicates that a description MUST be treated as canceling the current SDP negotiation and moving the SDP offer and answer back to what it was in the previous stable state. Note the local or remote SDP descriptions in the previous stable state could be null if there has not yet been a successful offer-answer negotiation.", + "type": "string", + "enum": [ + "rollback" + ] + } + ] + }, + "RtcSessionDescription": { + "description": "SessionDescription is used to expose local and remote session descriptions.", + "type": "object", + "properties": { + "sdp": { + "description": "SDP string.", + "type": "string" + }, + "type": { + "description": "SDP type.", + "allOf": [ + { + "$ref": "#/components/schemas/RtcSdpType" + } + ] } }, - "summary": "Convert pressure units.", - "tags": [ - "unit" + "required": [ + "sdp", + "type" ] - } - }, - "/unit/conversion/temperature/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a temperature unit value to another temperature unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_temperature_unit_conversion", - "parameters": [ + }, + "SceneSelectionType": { + "description": "The type of scene selection change", + "oneOf": [ { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitTemperature" - } + "description": "Replaces the selection", + "type": "string", + "enum": [ + "replace" + ] }, { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitTemperature" - } + "description": "Adds to the selection", + "type": "string", + "enum": [ + "add" + ] }, { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } + "description": "Removes from the selection", + "type": "string", + "enum": [ + "remove" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitTemperatureConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + ] + }, + "SceneToolType": { + "description": "The type of scene's active tool", + "type": "string", + "enum": [ + "camera_revolve", + "select", + "move", + "sketch_line", + "sketch_curve", + "sketch_curve_mod" + ] + }, + "SelectGet": { + "description": "The response from the `SelectGet` command.", + "type": "object", + "properties": { + "entity_ids": { + "description": "The UUIDs of the selected entities.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } - }, - "4XX": { - "$ref": "#/components/responses/Error" - }, - "5XX": { - "$ref": "#/components/responses/Error" } }, - "summary": "Convert temperature units.", - "tags": [ - "unit" + "required": [ + "entity_ids" ] - } - }, - "/unit/conversion/torque/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a torque unit value to another torque unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_torque_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitTorque" - } + }, + "SelectWithPoint": { + "description": "The response from the `SelectWithPoint` command.", + "type": "object", + "properties": { + "entity_id": { + "nullable": true, + "description": "The UUID of the entity that was selected.", + "type": "string", + "format": "uuid" + } + } + }, + "Session": { + "description": "An authentication session.\n\nFor our UIs, these are automatically created by Next.js.", + "type": "object", + "properties": { + "created_at": { + "title": "DateTime", + "description": "The date and time the session was created.", + "type": "string", + "format": "date-time" }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitTorque" - } + "expires": { + "title": "DateTime", + "description": "The date and time the session expires.", + "type": "string", + "format": "date-time" }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitTorqueConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "id": { + "description": "The unique identifier for the session.", + "type": "string" + }, + "session_token": { + "description": "The session token.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "updated_at": { + "title": "DateTime", + "description": "The date and time the session was last updated.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID of the user that the session belongs to.", + "type": "string" } }, - "summary": "Convert torque units.", - "tags": [ - "unit" + "required": [ + "created_at", + "expires", + "session_token", + "updated_at" ] - } - }, - "/unit/conversion/volume/{input_unit}/{output_unit}": { - "get": { - "description": "Convert a volume unit value to another volume unit value. This is a nice endpoint to use for helper functions.", - "operationId": "get_volume_unit_conversion", - "parameters": [ - { - "description": "The source format of the unit.", - "in": "path", - "name": "input_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitVolume" - } - }, - { - "description": "The output format of the unit.", - "in": "path", - "name": "output_unit", - "required": true, - "schema": { - "$ref": "#/components/schemas/UnitVolume" - } - }, - { - "description": "The initial value.", - "in": "query", - "name": "value", - "required": true, - "schema": { - "format": "double", - "type": "number" + }, + "Solid3dGetAllEdgeFaces": { + "description": "The response from the `Solid3dGetAllEdgeFaces` command.", + "type": "object", + "properties": { + "faces": { + "description": "The UUIDs of the faces.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UnitVolumeConversion" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + }, + "required": [ + "faces" + ] + }, + "Solid3dGetAllOppositeEdges": { + "description": "The response from the `Solid3dGetAllOppositeEdges` command.", + "type": "object", + "properties": { + "edges": { + "description": "The UUIDs of the edges.", + "type": "array", + "items": { + "type": "string", + "format": "uuid" } + } + }, + "required": [ + "edges" + ] + }, + "Solid3dGetNextAdjacentEdge": { + "description": "The response from the `Solid3dGetNextAdjacentEdge` command.", + "type": "object", + "properties": { + "edge": { + "nullable": true, + "description": "The UUID of the edge.", + "type": "string", + "format": "uuid" + } + } + }, + "Solid3dGetOppositeEdge": { + "description": "The response from the `Solid3dGetOppositeEdge` command.", + "type": "object", + "properties": { + "edge": { + "description": "The UUID of the edge.", + "type": "string", + "format": "uuid" + } + }, + "required": [ + "edge" + ] + }, + "Solid3dGetPrevAdjacentEdge": { + "description": "The response from the `Solid3dGetPrevAdjacentEdge` command.", + "type": "object", + "properties": { + "edge": { + "nullable": true, + "description": "The UUID of the edge.", + "type": "string", + "format": "uuid" + } + } + }, + "StlStorage": { + "description": "Export storage.", + "oneOf": [ + { + "description": "Plaintext encoding.", + "type": "string", + "enum": [ + "ascii" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Binary STL encoding.\n\nThis is the default setting.", + "type": "string", + "enum": [ + "binary" + ] + } + ] + }, + "SuccessWebSocketResponse": { + "description": "Successful Websocket response.", + "type": "object", + "properties": { + "request_id": { + "nullable": true, + "description": "Which request this is a response to. If the request was a modeling command, this is the modeling command ID. If no request ID was sent, this will be null.", + "type": "string", + "format": "uuid" }, - "5XX": { - "$ref": "#/components/responses/Error" + "resp": { + "description": "The data sent with a successful response. This will be flattened into a 'type' and 'data' field.", + "allOf": [ + { + "$ref": "#/components/schemas/OkWebSocketResponseData" + } + ] + }, + "success": { + "description": "Always true", + "type": "boolean" } }, - "summary": "Convert volume units.", - "tags": [ - "unit" + "required": [ + "resp", + "success" ] - } - }, - "/user": { - "delete": { - "description": "This endpoint requires authentication by any KittyCAD user. It deletes the authenticated user from KittyCAD's database.\nThis call will only succeed if all invoices associated with the user have been paid in full and there is no outstanding balance.", - "operationId": "delete_user_self", - "responses": { - "204": { - "description": "successful deletion", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + }, + "SurfaceArea": { + "description": "The surface area response.", + "type": "object", + "properties": { + "output_unit": { + "description": "The output unit for the surface area.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitArea" } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + "surface_area": { + "description": "The surface area.", + "type": "number", + "format": "double" } }, - "summary": "Delete your user.", - "tags": [ - "users" + "required": [ + "output_unit", + "surface_area" ] }, - "get": { - "description": "Get the user information for the authenticated user.\nAlternatively, you can also use the `/users/me` endpoint.", - "operationId": "get_user_self", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/User" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "System": { + "description": "Co-ordinate system definition.\n\nThe `up` axis must be orthogonal to the `forward` axis.\n\nSee [cglearn.eu] for background reading.\n\n[cglearn.eu](https://cglearn.eu/pub/computer-graphics/introduction-to-geometry#material-coordinate-systems-1)", + "type": "object", + "properties": { + "forward": { + "description": "Axis the front face of a model looks along.", + "allOf": [ + { + "$ref": "#/components/schemas/AxisDirectionPair" } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + "up": { + "description": "Axis pointing up and away from a model.", + "allOf": [ + { + "$ref": "#/components/schemas/AxisDirectionPair" + } + ] } }, - "summary": "Get your user.", - "tags": [ - "users" + "required": [ + "forward", + "up" ] }, - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_user_self", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "TakeSnapshot": { + "description": "The response from the `TakeSnapshot` command.", + "type": "object", + "properties": { + "contents": { + "title": "String", + "description": "Contents of the image.", + "type": "string", + "format": "byte" + } + }, + "required": [ + "contents" + ] + }, + "UnitAngle": { + "description": "The valid types of angle formats.", + "oneOf": [ + { + "description": "Degrees ", + "type": "string", + "enum": [ + "degrees" + ] + }, + { + "description": "Radians ", + "type": "string", + "enum": [ + "radians" + ] + } + ] + }, + "UnitAngleConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitAngle" + } + ] + }, + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitAngle" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] }, - "put": { - "description": "This endpoint requires authentication by any KittyCAD user. It updates information about the authenticated user.", - "operationId": "update_user_self", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateUser" - } - } + "UnitArea": { + "description": "The valid types of area units.", + "oneOf": [ + { + "description": "Square centimeters ", + "type": "string", + "enum": [ + "cm2" + ] }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/User" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + { + "description": "Square decimeters ", + "type": "string", + "enum": [ + "dm2" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Square feet ", + "type": "string", + "enum": [ + "ft2" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Update your user.", - "tags": [ - "users" - ] - } - }, - "/user/api-calls": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns the API calls for the authenticated user.\nThe API calls are returned in order of creation, with the most recently created API calls first.", - "operationId": "user_list_api_calls", - "parameters": [ { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + "description": "Square inches ", + "type": "string", + "enum": [ + "in2" + ] }, { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "description": "Square kilometers ", + "type": "string", + "enum": [ + "km2" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "Square meters ", + "type": "string", + "enum": [ + "m2" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Square millimeters ", + "type": "string", + "enum": [ + "mm2" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List API calls for your user.", - "tags": [ - "api-calls" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/user/api-calls/{id}": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API call for the user.", - "operationId": "get_api_call_for_user", - "parameters": [ { - "description": "The ID of the API call.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } + "description": "Square yards ", + "type": "string", + "enum": [ + "yd2" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiCallWithPrice" - } + ] + }, + "UnitAreaConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitArea" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitArea" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get an API call for a user.", - "tags": [ - "api-calls" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/user/api-tokens": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns the API tokens for the authenticated user.\nThe API tokens are returned in order of creation, with the most recently created API tokens first.", - "operationId": "list_api_tokens_for_user", - "parameters": [ + }, + "UnitCurrent": { + "description": "The valid types of current units.", + "oneOf": [ { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + "description": "Amperes ", + "type": "string", + "enum": [ + "amperes" + ] }, { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "description": "Microamperes ", + "type": "string", + "enum": [ + "microamperes" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } + "description": "Milliamperes ", + "type": "string", + "enum": [ + "milliamperes" + ] + }, + { + "description": "Nanoamperes ", + "type": "string", + "enum": [ + "nanoamperes" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiTokenResultsPage" - } + ] + }, + "UnitCurrentConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitCurrent" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List API tokens for your user.", - "tags": [ - "api-tokens" - ], - "x-dropshot-pagination": { - "required": [] - } - }, - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_api_token_for_user", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitCurrent" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] }, - "post": { - "description": "This endpoint requires authentication by any KittyCAD user. It creates a new API token for the authenticated user.", - "operationId": "create_api_token_for_user", - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiToken" - } - } - }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } - }, - "4XX": { - "$ref": "#/components/responses/Error" + "UnitDensity": { + "description": "The valid types for density units.", + "oneOf": [ + { + "description": "Pounds per cubic feet.", + "type": "string", + "enum": [ + "lb:ft3" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Kilograms per cubic meter.", + "type": "string", + "enum": [ + "kg:m3" + ] } - }, - "summary": "Create a new API token for your user.", - "tags": [ - "api-tokens" ] - } - }, - "/user/api-tokens/{token}": { - "delete": { - "description": "This endpoint requires authentication by any KittyCAD user. It deletes the requested API token for the user.\nThis endpoint does not actually delete the API token from the database. It merely marks the token as invalid. We still want to keep the token in the database for historical purposes.", - "operationId": "delete_api_token_for_user", - "parameters": [ + }, + "UnitEnergy": { + "description": "The valid types of energy units.", + "oneOf": [ { - "description": "The API token.", - "in": "path", - "name": "token", - "required": true, - "schema": { - "format": "uuid", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "successful deletion", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "British Thermal Unit (BTU) ", + "type": "string", + "enum": [ + "btu" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Electron Volts (eV) ", + "type": "string", + "enum": [ + "electronvolts" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Joules (or watt-seconds) ", + "type": "string", + "enum": [ + "joules" + ] + }, + { + "description": "Kilocalories (often just called calories) ", + "type": "string", + "enum": [ + "kilocalories" + ] + }, + { + "description": "Kilowatt hours (kWh) ", + "type": "string", + "enum": [ + "kilowatt_hours" + ] + }, + { + "description": "Watt hours (Wh) ", + "type": "string", + "enum": [ + "watt_hours" + ] } - }, - "summary": "Delete an API token for your user.", - "tags": [ - "api-tokens" ] }, - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API token for the user.", - "operationId": "get_api_token_for_user", - "parameters": [ - { - "description": "The API token.", - "in": "path", - "name": "token", - "required": true, - "schema": { - "format": "uuid", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiToken" - } + "UnitEnergyConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitEnergy" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitEnergy" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get an API token for your user.", - "tags": [ - "api-tokens" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] }, - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_api_token_for_user", - "parameters": [ + "UnitForce": { + "description": "The valid types of force units.", + "oneOf": [ { - "description": "The API token.", - "in": "path", - "name": "token", - "required": true, - "schema": { - "format": "uuid", - "type": "string" - } + "description": "Dynes ", + "type": "string", + "enum": [ + "dynes" + ] + }, + { + "description": "Kiloponds ", + "type": "string", + "enum": [ + "kiloponds" + ] + }, + { + "description": "Micronewtons ", + "type": "string", + "enum": [ + "micronewtons" + ] + }, + { + "description": "Millinewtons ", + "type": "string", + "enum": [ + "millinewtons" + ] + }, + { + "description": "Newtons ", + "type": "string", + "enum": [ + "newtons" + ] + }, + { + "description": "Poundals ", + "type": "string", + "enum": [ + "poundals" + ] + }, + { + "description": "Pounds ", + "type": "string", + "enum": [ + "pounds" + ] } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "UnitForceConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitForce" + } + ] + }, + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitForce" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/user/extended": { - "get": { - "description": "Get the user information for the authenticated user.\nAlternatively, you can also use the `/users-extended/me` endpoint.", - "operationId": "get_user_self_extended", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ExtendedUser" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + }, + "UnitFrequency": { + "description": "The valid types of frequency units.", + "oneOf": [ + { + "description": "Gigahertz ", + "type": "string", + "enum": [ + "gigahertz" + ] + }, + { + "description": "Hertz ", + "type": "string", + "enum": [ + "hertz" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Kilohertz ", + "type": "string", + "enum": [ + "kilohertz" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Megahertz ", + "type": "string", + "enum": [ + "megahertz" + ] + }, + { + "description": "Microhertz ", + "type": "string", + "enum": [ + "microhertz" + ] + }, + { + "description": "Millihertz ", + "type": "string", + "enum": [ + "millihertz" + ] + }, + { + "description": "Nanohertz ", + "type": "string", + "enum": [ + "nanohertz" + ] + }, + { + "description": "Terahertz ", + "type": "string", + "enum": [ + "terahertz" + ] } - }, - "summary": "Get extended information about your user.", - "tags": [ - "users" ] - } - }, - "/user/front-hash": { - "get": { - "description": "This info is sent to front when initialing the front chat, it prevents impersonations using js hacks in the browser", - "operationId": "get_user_front_hash_self", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "title": "String", - "type": "string" - } + }, + "UnitFrequencyConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitFrequency" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get your user's front verification hash.", - "tags": [ - "users", - "hidden" - ] - } - }, - "/user/onboarding": { - "get": { - "description": "Checks key part of their api usage to determine their onboarding progress", - "operationId": "get_user_onboarding_self", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Onboarding" - } + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitFrequency" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get your user's onboarding status.", - "tags": [ - "users", - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/user/payment": { - "delete": { - "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It deletes the payment information for the authenticated user.", - "operationId": "delete_payment_information_for_user", - "responses": { - "204": { - "description": "successful deletion", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + }, + "UnitLength": { + "description": "The valid types of length units.", + "oneOf": [ + { + "description": "Centimeters ", + "type": "string", + "enum": [ + "cm" + ] + }, + { + "description": "Feet ", + "type": "string", + "enum": [ + "ft" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Inches ", + "type": "string", + "enum": [ + "in" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Meters ", + "type": "string", + "enum": [ + "m" + ] + }, + { + "description": "Millimeters ", + "type": "string", + "enum": [ + "mm" + ] + }, + { + "description": "Yards ", + "type": "string", + "enum": [ + "yd" + ] } - }, - "summary": "Delete payment info for your user.", - "tags": [ - "payments" ] }, - "get": { - "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It gets the payment information for the authenticated user.", - "operationId": "get_payment_information_for_user", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Customer" - } + "UnitLengthConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitLength" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get payment info about your user.", - "tags": [ - "payments" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] }, - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_payment_information_for_user", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "UnitMass": { + "description": "The valid types of mass units.", + "oneOf": [ + { + "description": "Grams ", + "type": "string", + "enum": [ + "g" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Kilograms ", + "type": "string", + "enum": [ + "kg" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Pounds ", + "type": "string", + "enum": [ + "lb" + ] } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" ] }, - "post": { - "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It creates the payment information for the authenticated user.", - "operationId": "create_payment_information_for_user", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/BillingInfo" - } - } + "UnitMassConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" }, - "required": true - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Customer" - } - } - }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Create payment info for your user.", - "tags": [ - "payments" - ] - }, - "put": { - "description": "This includes billing address, phone, and name.\nThis endpoint requires authentication by any KittyCAD user. It updates the payment information for the authenticated user.", - "operationId": "update_payment_information_for_user", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/BillingInfo" + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" } - } + ] }, - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Customer" - } + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitMass" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Update payment info for your user.", - "tags": [ - "payments" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/user/payment/balance": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It gets the balance information for the authenticated user.", - "operationId": "get_payment_balance_for_user", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CustomerBalance" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + }, + "UnitPower": { + "description": "The valid types of power units.", + "oneOf": [ + { + "description": "British thermal units (BTU) per minute ", + "type": "string", + "enum": [ + "btu_per_minute" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Horsepower (hp) ", + "type": "string", + "enum": [ + "horsepower" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Kilowatts ", + "type": "string", + "enum": [ + "kilowatts" + ] + }, + { + "description": "Metric horsepower (PS) ", + "type": "string", + "enum": [ + "metric_horsepower" + ] + }, + { + "description": "Microwatts ", + "type": "string", + "enum": [ + "microwatts" + ] + }, + { + "description": "Millwatts ", + "type": "string", + "enum": [ + "milliwatts" + ] + }, + { + "description": "Watts ", + "type": "string", + "enum": [ + "watts" + ] } - }, - "summary": "Get balance for your user.", - "tags": [ - "payments" ] - } - }, - "/user/payment/intent": { - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_create_payment_intent_for_user", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + }, + "UnitPowerConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" - ] - }, - "post": { - "description": "This endpoint requires authentication by any KittyCAD user. It creates a new payment intent for the authenticated user.", - "operationId": "create_payment_intent_for_user", - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PaymentIntent" - } + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitPower" } - }, - "description": "successful creation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitPower" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Create a payment intent for your user.", - "tags": [ - "payments", - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/user/payment/invoices": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It lists invoices for the authenticated user.", - "operationId": "list_invoices_for_user", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/Invoice" - }, - "title": "Array_of_Invoice", - "type": "array" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + }, + "UnitPressure": { + "description": "The valid types of pressure units.", + "oneOf": [ + { + "description": "Atmospheres ", + "type": "string", + "enum": [ + "atmospheres" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Bars ", + "type": "string", + "enum": [ + "bars" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Hectopascals ", + "type": "string", + "enum": [ + "hectopascals" + ] + }, + { + "description": "Kilopascals ", + "type": "string", + "enum": [ + "kilopascals" + ] + }, + { + "description": "Millibars ", + "type": "string", + "enum": [ + "millibars" + ] + }, + { + "description": "Pascals ", + "type": "string", + "enum": [ + "pascals" + ] + }, + { + "description": "Pounds per square inch (PSI) - ", + "type": "string", + "enum": [ + "psi" + ] } - }, - "summary": "List invoices for your user.", - "tags": [ - "payments" ] - } - }, - "/user/payment/methods": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It lists payment methods for the authenticated user.", - "operationId": "list_payment_methods_for_user", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/PaymentMethod" - }, - "title": "Array_of_PaymentMethod", - "type": "array" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + }, + "UnitPressureConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List payment methods for your user.", - "tags": [ - "payments" - ] - } - }, - "/user/payment/methods/{id}": { - "delete": { - "description": "This endpoint requires authentication by any KittyCAD user. It deletes the specified payment method for the authenticated user.", - "operationId": "delete_payment_method_for_user", - "parameters": [ - { - "description": "The ID of the payment method.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "successful deletion", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitPressure" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitPressure" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Delete a payment method for your user.", - "tags": [ - "payments", - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] }, - "options": { - "description": "This is necessary for some preflight requests, specifically POST, PUT, and DELETE.", - "operationId": "options_payment_methods_for_user", - "parameters": [ + "UnitTemperature": { + "description": "The valid types of temperature units.", + "oneOf": [ { - "description": "The ID of the payment method.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "Celsius ", + "type": "string", + "enum": [ + "celsius" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Fahrenheit ", + "type": "string", + "enum": [ + "fahrenheit" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" + { + "description": "Kelvin ", + "type": "string", + "enum": [ + "kelvin" + ] + }, + { + "description": "Rankine ", + "type": "string", + "enum": [ + "rankine" + ] } - }, - "summary": "OPTIONS endpoint.", - "tags": [ - "hidden" ] - } - }, - "/user/payment/tax": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It will return an error if the customer's information is not valid for automatic tax. Otherwise, it will return an empty successful response.", - "operationId": "validate_customer_tax_information_for_user", - "responses": { - "204": { - "description": "successful operation, no content", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + }, + "UnitTemperatureConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Validate a customer's information is correct and valid for automatic tax.", - "tags": [ - "payments", - "hidden" - ] - } - }, - "/user/session/{token}": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns details of the requested API token for the user.", - "operationId": "get_session_for_user", - "parameters": [ - { - "description": "The API token.", - "in": "path", - "name": "token", - "required": true, - "schema": { - "format": "uuid", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Session" - } + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitTemperature" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitTemperature" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get a session for your user.", - "tags": [ - "users" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/users": { - "get": { - "description": "This endpoint required authentication by a KittyCAD employee. The users are returned in order of creation, with the most recently created users first.", - "operationId": "list_users", - "parameters": [ - { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } - }, + }, + "UnitTorque": { + "description": "The valid types of torque units.", + "oneOf": [ { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "description": "Newton metres ", + "type": "string", + "enum": [ + "newton_metres" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } + "description": "Pound foot ", + "type": "string", + "enum": [ + "pound_foot" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UserResultsPage" - } + ] + }, + "UnitTorqueConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitTorque" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" }, - "5XX": { - "$ref": "#/components/responses/Error" + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitTorque" + } + ] + }, + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" + }, + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "List users.", - "tags": [ - "users", - "hidden" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/users-extended": { - "get": { - "description": "This endpoint required authentication by a KittyCAD employee. The users are returned in order of creation, with the most recently created users first.", - "operationId": "list_users_extended", - "parameters": [ + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" + ] + }, + "UnitVolume": { + "description": "The valid types of volume units.", + "oneOf": [ { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + "description": "Cubic centimeters (cc or cm³) ", + "type": "string", + "enum": [ + "cm3" + ] }, { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "description": "Cubic feet (ft³) ", + "type": "string", + "enum": [ + "ft3" + ] }, { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ExtendedUserResultsPage" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "Cubic inches (cu in or in³) ", + "type": "string", + "enum": [ + "in3" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "Cubic meters (m³) ", + "type": "string", + "enum": [ + "m3" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "List users with extended information.", - "tags": [ - "users", - "hidden" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/users-extended/{id}": { - "get": { - "description": "To get information about yourself, use `/users-extended/me` as the endpoint. By doing so you will get the user information for the authenticated user.\nAlternatively, to get information about the authenticated user, use `/user/extended` endpoint.\nTo get information about any KittyCAD user, you must be a KittyCAD employee.", - "operationId": "get_user_extended", - "parameters": [ { - "description": "The user ID.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ExtendedUser" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } - } + "description": "Cubic yards (yd³) ", + "type": "string", + "enum": [ + "yd3" + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + { + "description": "US Fluid Ounces (fl oz) ", + "type": "string", + "enum": [ + "usfloz" + ] }, - "5XX": { - "$ref": "#/components/responses/Error" - } - }, - "summary": "Get extended information about a user.", - "tags": [ - "users", - "hidden" - ] - } - }, - "/users/{id}": { - "get": { - "description": "To get information about yourself, use `/users/me` as the endpoint. By doing so you will get the user information for the authenticated user.\nAlternatively, to get information about the authenticated user, use `/user` endpoint.\nTo get information about any KittyCAD user, you must be a KittyCAD employee.", - "operationId": "get_user", - "parameters": [ { - "description": "The user ID.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } + "description": "US Gallons (gal US) ", + "type": "string", + "enum": [ + "usgal" + ] + }, + { + "description": "Liters (l) ", + "type": "string", + "enum": [ + "l" + ] + }, + { + "description": "Milliliters (ml) ", + "type": "string", + "enum": [ + "ml" + ] } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/User" - } + ] + }, + "UnitVolumeConversion": { + "description": "Result of converting between units.", + "type": "object", + "properties": { + "completed_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was completed.", + "type": "string", + "format": "date-time" + }, + "created_at": { + "title": "DateTime", + "description": "The time and date the API call was created.", + "type": "string", + "format": "date-time" + }, + "error": { + "nullable": true, + "description": "The error the function returned, if any.", + "type": "string" + }, + "id": { + "description": "The unique identifier of the API call.\n\nThis is the same as the API call ID.", + "allOf": [ + { + "$ref": "#/components/schemas/Uuid" + } + ] + }, + "input": { + "description": "The input value.", + "default": 0.0, + "type": "number", + "format": "double" + }, + "input_unit": { + "description": "The source format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" + ] + }, + "output": { + "nullable": true, + "description": "The resulting value.", + "type": "number", + "format": "double" + }, + "output_unit": { + "description": "The output format of the unit conversion.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" } - } + ] }, - "4XX": { - "$ref": "#/components/responses/Error" + "started_at": { + "nullable": true, + "title": "DateTime", + "description": "The time and date the API call was started.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "status": { + "description": "The status of the API call.", + "allOf": [ + { + "$ref": "#/components/schemas/ApiCallStatus" + } + ] + }, + "updated_at": { + "title": "DateTime", + "description": "The time and date the API call was last updated.", + "type": "string", + "format": "date-time" + }, + "user_id": { + "description": "The user ID of the user who created the API call.", + "type": "string" } }, - "summary": "Get a user.", - "tags": [ - "users", - "hidden" + "required": [ + "created_at", + "id", + "input_unit", + "output_unit", + "status", + "updated_at" ] - } - }, - "/users/{id}/api-calls": { - "get": { - "description": "This endpoint requires authentication by any KittyCAD user. It returns the API calls for the authenticated user if \"me\" is passed as the user id.\nAlternatively, you can use the `/user/api-calls` endpoint to get the API calls for your user.\nIf the authenticated user is a KittyCAD employee, then the API calls are returned for the user specified by the user id.\nThe API calls are returned in order of creation, with the most recently created API calls first.", - "operationId": "list_api_calls_for_user", - "parameters": [ - { - "description": "The user ID.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } + }, + "UpdateUser": { + "description": "The user-modifiable parts of a User.", + "type": "object", + "properties": { + "company": { + "description": "The user's company.", + "type": "string" }, - { - "description": "Maximum number of items returned by a single call", - "in": "query", - "name": "limit", - "schema": { - "format": "uint32", - "minimum": 1, - "nullable": true, - "type": "integer" - } + "discord": { + "description": "The user's Discord handle.", + "type": "string" }, - { - "description": "Token returned by previous call to retrieve the subsequent page", - "in": "query", - "name": "page_token", - "schema": { - "nullable": true, - "type": "string" - } + "first_name": { + "description": "The user's first name.", + "type": "string" }, - { - "in": "query", - "name": "sort_by", - "schema": { - "$ref": "#/components/schemas/CreatedAtSortMode" - } + "github": { + "description": "The user's GitHub handle.", + "type": "string" + }, + "last_name": { + "description": "The user's last name.", + "type": "string" + }, + "phone": { + "title": "String", + "description": "The user's phone number.", + "default": "", + "type": "string", + "format": "phone" } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ApiCallWithPriceResultsPage" - } - } - }, - "description": "successful operation", - "headers": { - "Access-Control-Allow-Credentials": { - "description": "Access-Control-Allow-Credentials header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Headers": { - "description": "Access-Control-Allow-Headers header. This is a comma-separated list of headers.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Methods": { - "description": "Access-Control-Allow-Methods header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - }, - "Access-Control-Allow-Origin": { - "description": "Access-Control-Allow-Origin header.", - "required": true, - "schema": { - "type": "string" - }, - "style": "simple" - } + } + }, + "User": { + "description": "A user.", + "type": "object", + "properties": { + "company": { + "description": "The user's company.", + "type": "string" + }, + "created_at": { + "title": "DateTime", + "description": "The date and time the user was created.", + "type": "string", + "format": "date-time" + }, + "discord": { + "description": "The user's Discord handle.", + "type": "string" + }, + "email": { + "description": "The email address of the user.", + "type": "string", + "format": "email" + }, + "email_verified": { + "nullable": true, + "title": "DateTime", + "description": "The date and time the email address was verified.", + "type": "string", + "format": "date-time" + }, + "first_name": { + "description": "The user's first name.", + "type": "string" + }, + "github": { + "description": "The user's GitHub handle.", + "type": "string" + }, + "id": { + "description": "The unique identifier for the user.", + "type": "string" + }, + "image": { + "title": "String", + "description": "The image avatar for the user. This is a URL.", + "type": "string", + "format": "uri" + }, + "last_name": { + "description": "The user's last name.", + "type": "string" + }, + "name": { + "description": "The name of the user. This is auto populated at first from the authentication provider (if there was a name). It can be updated by the user by updating their `first_name` and `last_name` fields.", + "type": "string" + }, + "phone": { + "title": "String", + "description": "The user's phone number.", + "default": "", + "type": "string", + "format": "phone" + }, + "updated_at": { + "title": "DateTime", + "description": "The date and time the user was last updated.", + "type": "string", + "format": "date-time" + } + }, + "required": [ + "created_at", + "image", + "updated_at" + ] + }, + "UserResultsPage": { + "description": "A single page of results", + "type": "object", + "properties": { + "items": { + "description": "list of items on this page of results", + "type": "array", + "items": { + "$ref": "#/components/schemas/User" } }, - "4XX": { - "$ref": "#/components/responses/Error" + "next_page": { + "nullable": true, + "description": "token used to fetch the next page of results (if any)", + "type": "string" + } + }, + "required": [ + "items" + ] + }, + "Uuid": { + "description": "A uuid.\n\nA Version 4 UUID is a universally unique identifier that is generated using random numbers.", + "type": "string", + "format": "uuid" + }, + "VerificationToken": { + "description": "A verification token for a user.\n\nThis is typically used to verify a user's email address.", + "type": "object", + "properties": { + "created_at": { + "title": "DateTime", + "description": "The date and time the verification token was created.", + "type": "string", + "format": "date-time" + }, + "expires": { + "title": "DateTime", + "description": "The date and time the verification token expires.", + "type": "string", + "format": "date-time" }, - "5XX": { - "$ref": "#/components/responses/Error" + "id": { + "description": "The token used for verification. This is used as the id for the table since it is unique per record.", + "type": "string" + }, + "identifier": { + "description": "The identifier for the user. This is typically the user's email address since that is what we are verifying.", + "type": "string" + }, + "updated_at": { + "title": "DateTime", + "description": "The date and time the verification token was last updated.", + "type": "string", + "format": "date-time" } }, - "summary": "List API calls for a user.", - "tags": [ - "api-calls", - "hidden" - ], - "x-dropshot-pagination": { - "required": [] - } - } - }, - "/ws/executor/term": { - "get": { - "description": "Attach to a docker container to create an interactive terminal.", - "operationId": "create_executor_term", - "responses": { - "default": { - "content": { - "*/*": { - "schema": {} + "required": [ + "created_at", + "expires", + "updated_at" + ] + }, + "Volume": { + "description": "The volume response.", + "type": "object", + "properties": { + "output_unit": { + "description": "The output unit for the volume.", + "allOf": [ + { + "$ref": "#/components/schemas/UnitVolume" } - }, - "description": "" + ] + }, + "volume": { + "description": "The volume.", + "type": "number", + "format": "double" } }, - "summary": "Create a terminal.", - "tags": [ - "executor", - "hidden" - ], - "x-dropshot-websocket": {} - } - }, - "/ws/modeling/commands": { - "get": { - "description": "Pass those commands to the engine via websocket, and pass responses back to the client. Basically, this is a websocket proxy between the frontend/client and the engine.", - "operationId": "modeling_commands_ws", - "parameters": [ + "required": [ + "output_unit", + "volume" + ] + }, + "WebSocketRequest": { + "description": "The websocket messages the server receives.", + "oneOf": [ { - "description": "Frames per second of the video feed.", - "in": "query", - "name": "fps", - "schema": { - "format": "uint32", - "minimum": 0, - "type": "integer" - } + "description": "The trickle ICE candidate request.", + "type": "object", + "properties": { + "candidate": { + "description": "Information about the ICE candidate.", + "allOf": [ + { + "$ref": "#/components/schemas/RtcIceCandidateInit" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "trickle_ice" + ] + } + }, + "required": [ + "candidate", + "type" + ] }, { - "description": "If true, engine will render video frames as fast as it can.", - "in": "query", - "name": "unlocked_framerate", - "schema": { - "type": "boolean" - } + "description": "The SDP offer request.", + "type": "object", + "properties": { + "offer": { + "description": "The session description.", + "allOf": [ + { + "$ref": "#/components/schemas/RtcSessionDescription" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "sdp_offer" + ] + } + }, + "required": [ + "offer", + "type" + ] }, { - "description": "Height of the video feed. Must be a multiple of 4.", - "in": "query", - "name": "video_res_height", - "schema": { - "format": "uint32", - "minimum": 0, - "type": "integer" - } + "description": "The modeling command request.", + "type": "object", + "properties": { + "cmd": { + "description": "Which command to submit to the Kittycad engine.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmd" + } + ] + }, + "cmd_id": { + "description": "ID of command being submitted.", + "allOf": [ + { + "$ref": "#/components/schemas/ModelingCmdId" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "modeling_cmd_req" + ] + } + }, + "required": [ + "cmd", + "cmd_id", + "type" + ] }, { - "description": "Width of the video feed. Must be a multiple of 4.", - "in": "query", - "name": "video_res_width", - "schema": { - "format": "uint32", - "minimum": 0, - "type": "integer" - } + "description": "The client-to-server Ping to ensure the WebSocket stays alive.", + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "ping" + ] + } + }, + "required": [ + "type" + ] }, { - "description": "If true, will start a webrtc connection.", - "in": "query", - "name": "webrtc", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "default": { - "content": { - "*/*": { - "schema": {} + "description": "The response to a metrics collection request from the server.", + "type": "object", + "properties": { + "metrics": { + "description": "Collected metrics from the Client's end of the engine connection.", + "allOf": [ + { + "$ref": "#/components/schemas/ClientMetrics" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "metrics_response" + ] } }, - "description": "" + "required": [ + "metrics", + "type" + ] } - }, - "summary": "Open a websocket which accepts modeling commands.", - "tags": [ - "modeling", - "hidden" - ], - "x-dropshot-websocket": {} + ] + }, + "WebSocketResponse": { + "description": "Websocket responses can either be successful or unsuccessful. Slightly different schemas in either case.", + "anyOf": [ + { + "description": "Response sent when a request succeeded.", + "allOf": [ + { + "$ref": "#/components/schemas/SuccessWebSocketResponse" + } + ] + }, + { + "description": "Response sent when a request did not succeed.", + "allOf": [ + { + "$ref": "#/components/schemas/FailureWebSocketResponse" + } + ] + } + ] } } }, "tags": [ { + "name": "ai", "description": "AI uses machine learning to generate 3D meshes.", "externalDocs": { "url": "https://docs.kittycad.io/api/ai" - }, - "name": "ai" + } }, { + "name": "api-calls", "description": "API calls that have been performed by users can be queried by the API. This is helpful for debugging as well as billing.", "externalDocs": { "url": "https://docs.kittycad.io/api/api-calls" - }, - "name": "api-calls" + } }, { + "name": "api-tokens", "description": "API tokens allow users to call the API outside of their session token that is used as a cookie in the user interface. Users can create, delete, and list their API tokens. But, of course, you need an API token to do this, so first be sure to generate one in the account UI.", "externalDocs": { "url": "https://docs.kittycad.io/api/api-tokens" - }, - "name": "api-tokens" + } }, { + "name": "apps", "description": "Endpoints for third party app grant flows.", "externalDocs": { "url": "https://docs.kittycad.io/api/apps" - }, - "name": "apps" + } }, { + "name": "beta", "description": "Beta API endpoints. We will not charge for these endpoints while they are in beta.", "externalDocs": { "url": "https://docs.kittycad.io/api/beta" - }, - "name": "beta" + } }, { + "name": "constant", "description": "Constants. These are helpful as helpers.", "externalDocs": { "url": "https://docs.kittycad.io/api/constant" - }, - "name": "constant" + } }, { + "name": "executor", "description": "Endpoints that allow for code execution or creation of code execution environments.", "externalDocs": { "url": "https://docs.kittycad.io/api/executor" - }, - "name": "executor" + } }, { + "name": "file", "description": "CAD file operations. Create, get, and list CAD file conversions. More endpoints will be added here in the future as we build out transforms, etc on CAD models.", "externalDocs": { "url": "https://docs.kittycad.io/api/file" - }, - "name": "file" + } }, { + "name": "hidden", "description": "Hidden API endpoints that should not show up in the docs.", "externalDocs": { "url": "https://docs.kittycad.io/api/hidden" - }, - "name": "hidden" + } }, { + "name": "meta", "description": "Meta information about the API.", "externalDocs": { "url": "https://docs.kittycad.io/api/meta" - }, - "name": "meta" + } }, { + "name": "modeling", "description": "Modeling API for updating your 3D files using the KittyCAD engine.", "externalDocs": { "url": "https://docs.kittycad.io/api/modeling" - }, - "name": "modeling" + } }, { + "name": "oauth2", "description": "Endpoints that implement OAuth 2.0 grant flows.", "externalDocs": { "url": "https://docs.kittycad.io/api/oauth2" - }, - "name": "oauth2" + } }, { + "name": "payments", "description": "Operations around payments and billing.", "externalDocs": { "url": "https://docs.kittycad.io/api/payments" - }, - "name": "payments" + } }, { + "name": "unit", "description": "Unit conversion operations.", "externalDocs": { "url": "https://docs.kittycad.io/api/file" - }, - "name": "unit" + } }, { + "name": "users", "description": "A user is someone who uses the KittyCAD API. Here, we can create, delete, and list users. We can also get information about a user. Operations will only be authorized if the user is requesting information about themselves.", "externalDocs": { "url": "https://docs.kittycad.io/api/users" - }, - "name": "users" + } } ] } \ No newline at end of file