{ "openapi": "3.0.2", "info": { "title": "Flox Catalog Service", "description": "\n# Flox Catalog Service API\n\n![packages](https://api.preview.flox.dev/api/v1/catalog/status/badges/packages.svg)\n", "version": "vundefined", "x-logo": { "url": "https://fastapi.tiangolo.com/img/logo-margin/logo-teal.png" } }, "paths": { "/api/v1/catalog/search": { "get": { "tags": [ "catalog" ], "summary": "Search for packages", "description": "Search the catalog(s) under the given criteria for matching packages.\n\nRequired Query Parameters:\n- **seach_term**: The search term to search on.\n- **system**: This is returned but does not affect results\n\nOptional Query Parameters:\n- **catalogs**: Comma separated list of catalog names to search\n- **page**: Optional page number for pagination (def = 0)\n- **pageSize**: Optional page size for pagination (def = 10)\n\nReturns:\n- **PackageSearchResult**: A list of PackageInfo and the total result count", "operationId": "search_api_v1_catalog_search_get", "parameters": [ { "name": "search_term", "in": "query", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-\\.\\\\@%_,]{2,200}", "title": "Search Term" } }, { "name": "system", "in": "query", "required": true, "schema": { "$ref": "#/components/schemas/SystemEnum" } }, { "name": "catalogs", "in": "query", "required": false, "schema": { "default": "nixpkgs", "title": "Catalogs", "nullable": true, "type": "string" } }, { "name": "page", "in": "query", "required": false, "schema": { "type": "integer", "default": 0, "title": "Page" } }, { "name": "pageSize", "in": "query", "required": false, "schema": { "type": "integer", "default": 10, "title": "Pagesize" } } ], "responses": { "200": { "description": "A list of matching packages", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PackageSearchResult-Input" } } } }, "422": { "description": "The search terms given could not be processed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/packages/{attr_path}": { "get": { "tags": [ "catalog" ], "summary": "Shows avaliable packages of a specfic package", "description": "Returns a list of versions for a given attr_path\n\nRequired Query Parameters:\n- **attr_path**: The attr_path, must be valid.\n\nOptional Query Parameters:\n- **page**: Optional page number for pagination (def = 0)\n- **pageSize**: Optional page size for pagination (def = 10)\n\nReturns:\n- **PackageSearchResult**: A list of PackageInfo and the total result count", "operationId": "packages_api_v1_catalog_packages__attr_path__get", "parameters": [ { "name": "attr_path", "in": "path", "required": true, "schema": { "type": "string", "title": "Attr Path" } }, { "name": "page", "in": "query", "required": false, "schema": { "type": "integer", "default": 0, "title": "Page" } }, { "name": "pageSize", "in": "query", "required": false, "schema": { "type": "integer", "default": 10, "title": "Pagesize" } } ], "responses": { "200": { "description": "A list of packages attr_path", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PackagesResult-Input" } } } }, "404": { "description": "attr_path was not found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "Request validation error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/resolve": { "post": { "tags": [ "catalog" ], "summary": "Resolve a list of Package Groups", "description": "Resolves a list of package groups, each being a list of package descriptors.\n\nRequired Body:\n- **groups**: An object with an `items` array of PackageGroups to resolve.\n\nOptional Query Parameters:\n- **none**\n\nReturns:\n- **ResolvedPackageGroups**: A object with an `items` array of\n `ResolvedPackageGroup` items.\n\nResolution Rules:\n- Each `PackageGroup` is resolved independently.\n- Each page that has a package that meets each of the descriptors in that group is returned in the results\n- The latest page will include details for each package in the group from that page\n- The remainder pages are returned without details (to get those details... TBD)\n\nA Package Descriptor match:\n- **name**: [required] - is not used in matching, only for reference (TBD is\n there a uniqueness constraint?)\n- **attr_path**: [required] - this must match the nix attribute path exactly and in full\n- **version**: [optional] - Either a literal version to match or a **semver** constraint.\n This will be treated as a **semver** IFF TBD, otherwise it will be treated as\n a literal string match to the nix `version` field. If this is detected as a **semver**,\n packages whose `version` field cannot be parsed as a **semver** will be excluded.\n - **allow_pre_release**: [optional] - Defaults to False. Only applies\n when a **semver** constraint is given. If true, a `version` that can\n be parsed as a valid semver, that includes a pre-release suffix will\n be included as a candidate. Otherwise, they will be excluded.", "operationId": "resolve_api_v1_catalog_resolve_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PackageGroups" } } }, "required": true }, "responses": { "200": { "description": "A list of resolved package groups", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ResolvedPackageGroups-Input" } } } }, "422": { "description": "Request validation error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/settings/{key}": { "post": { "tags": [ "settings" ], "summary": "Adjust various settings", "description": "Adjusts various settings on the catalog service.\n\nQuery Parameters:\n- **key**: The the key to adjust.\n - \"plan\" - Enables the logging of the DB query plan for queries for\n **value** seconds. It will be scheduled to turn off automatically after\n that.", "operationId": "settings_api_v1_catalog_settings__key__post", "parameters": [ { "name": "key", "in": "path", "required": true, "schema": { "type": "string", "title": "Key" } }, { "name": "value", "in": "query", "required": true, "schema": { "type": "string", "title": "Value" } } ], "responses": { "200": { "description": "Successful.", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Request validation error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/status/catalog": { "get": { "tags": [ "status" ], "summary": "Get basic catalog database status", "description": "Gather some basic status values from the database.\n\nReturns:\n- **CatalogStatus**: A dictionary of various status values.", "operationId": "get_catalog_status_api_v1_catalog_status_catalog_get", "responses": { "200": { "description": "Catalog Status", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CatalogStatus" } } } }, "500": { "description": "Internal Server Erorr", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/status/service": { "get": { "tags": [ "status" ], "summary": "Get basic service status", "description": "Returns basic service status\n\nReturns:\n- **ServiceStatus**: A dictionary of various status values.", "operationId": "get_service_status_api_v1_catalog_status_service_get", "responses": { "200": { "description": "Service Status", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ServiceStatus-Input" } } } }, "500": { "description": "Internal Server Erorr", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/status/sentry-debug": { "get": { "tags": [ "status" ], "summary": "Trigger Error", "operationId": "trigger_error_api_v1_catalog_status_sentry_debug_get", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } } } }, "/api/v1/catalog/catalogs/": { "post": { "tags": [ "user_catalogs" ], "summary": "Create a new user catalog", "description": "Create a new user catalog\n\nRequired Query Parameters:\n- **name**: The name of the new catalog\n\n\nReturns:\n- **UserCatalog**: The new user catalog", "operationId": "create_catalog_api_v1_catalog_catalogs__post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "name", "in": "query", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Name" } } ], "responses": { "201": { "description": "The new user catalog was created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserCatalog" } } } }, "409": { "description": "The catalog name already exists", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The catalog name is invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/catalogs/{catalog_name}": { "get": { "tags": [ "user_catalogs" ], "summary": "Get user catalog metadata", "description": "Get user catalog metadata\n\nRequired Query Parameters:\n- **catalog_name**: The name of the catalog\n\n\nReturns:\n- **UserCatalog**: The user catalog", "operationId": "get_catalog_api_v1_catalog_catalogs__catalog_name__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } } ], "responses": { "200": { "description": "The user catalog metadata", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserCatalog" } } } }, "404": { "description": "The catalog with the given name was not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The search terms given could not be processed", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } }, "delete": { "tags": [ "user_catalogs" ], "summary": "Delete a user catalog", "description": "Delete a user catalog\n\nRequired Query Parameters:\n- **catalog_name**: The name of catalog to delete\n\n\nReturns:\n- **None**", "operationId": "delete_catalog_api_v1_catalog_catalogs__catalog_name__delete", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "501": { "description": "Deletion of user catalogs is not yet implemented", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The catalog name is invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/catalogs/{catalog_name}/packages": { "post": { "tags": [ "user_catalogs" ], "summary": "Create a new package in a user catalog", "description": "Creates a catalog package\n\nPath Parameters:\n- **catalog_name**: The name of catalog to place the package into\n\nRequired Query Parameters:\n- **name**: The name of package (attr_path) to create\n\nReturns:\n- **UserPackage**", "operationId": "create_catalog_package_api_v1_catalog_catalogs__catalog_name__packages_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } }, { "name": "name", "in": "query", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\.\\-_]{3,128}", "title": "Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPackageCreate" } } } }, "responses": { "201": { "description": "The new package was created", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPackage" } } } }, "200": { "description": "The package already exists", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPackage" } } } }, "404": { "description": "The catalog could not be found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "409": { "description": "The package already exists", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The request parameters are invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } }, "get": { "tags": [ "user_catalogs" ], "summary": "List packages available in a catalog", "description": "Lists available packages in a catalog\n\nPath Parameters:\n- **catalog_name**: The name of the catalog\n\nReturns:\n- **UserPackageList**", "operationId": "get_catalog_packages_api_v1_catalog_catalogs__catalog_name__packages_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } } ], "responses": { "200": { "description": "The list of packages", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPackageList" } } } }, "404": { "description": "The catalog could not be found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The request parameters are invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/catalogs/{catalog_name}/packages/{package_name}": { "get": { "tags": [ "user_catalogs" ], "summary": "Get package info", "description": "Get package info\n\nPath Parameters:\n- **catalog_name**: The name of the catalog\n- **package_name**: The name of the package\n\nReturns:\n- **UserPackage**", "operationId": "get_catalog_package_api_v1_catalog_catalogs__catalog_name__packages__package_name__get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } }, { "name": "package_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\.\\-_]{3,128}", "title": "Package Name" } } ], "responses": { "200": { "description": "The list of packages", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserPackage" } } } }, "404": { "description": "The catalog or package could not be found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The request parameters are invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/api/v1/catalog/catalogs/{catalog_name}/packages/{package_name}/builds": { "post": { "tags": [ "user_catalogs" ], "summary": "Submit a build of a particular package", "description": "Create a build of a package\n\nPath Parameters:\n- **catalog_name**: The name of the catalog\n- **package_name**: The name of the package\nBody Content:\n- **UserBuild**: The build info to submit\n\nReturns:\n- **UserBuildCreationResponse**", "operationId": "create_package_build_api_v1_catalog_catalogs__catalog_name__packages__package_name__builds_post", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } }, { "name": "package_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\.\\-_]{3,128}", "title": "Package Name" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserBuild-Input" } } } }, "responses": { "201": { "description": "The build was submitted successfully", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserBuildCreationResponse" } } } }, "200": { "description": "The build already exists", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserBuildCreationResponse" } } } }, "400": { "description": "The build cannot be published as requested", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "404": { "description": "The catalog or package could not be found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The request parameters are invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } }, "get": { "tags": [ "user_catalogs" ], "summary": "Get a list of builds for a given package", "description": "Get the list of builds for a given package\n\nPath Parameters:\n- **catalog_name**: The name of the catalog\n- **package_name**: The name of the package\n\nReturns:\n- **UserBuildList**", "operationId": "get_package_builds_api_v1_catalog_catalogs__catalog_name__packages__package_name__builds_get", "security": [ { "HTTPBearer": [] } ], "parameters": [ { "name": "catalog_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\-_]{3,64}", "title": "Catalog Name" } }, { "name": "package_name", "in": "path", "required": true, "schema": { "type": "string", "pattern": "[a-zA-Z0-9\\.\\-_]{3,128}", "title": "Package Name" } } ], "responses": { "200": { "description": "The list of builds", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UserBuildList-Input" } } } }, "404": { "description": "The catalog or package could not be found.", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "422": { "description": "The request parameters are invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } }, "/metrics/": { "get": { "summary": "Handle Metrics", "operationId": "handle_metrics_metrics__get", "responses": { "200": { "description": "Service Status", "content": { "application/json": { "schema": { "type": "string", "title": "Response 200 Handle Metrics Metrics Get" } } } }, "422": { "description": "Unprocessable Entity", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } } } } }, "components": { "schemas": { "CatalogPage-Input": { "properties": { "page": { "type": "integer", "title": "Page" }, "url": { "type": "string", "title": "Url" }, "packages": { "title": "Packages", "nullable": true, "items": { "$ref": "#/components/schemas/ResolvedPackageDescriptor" }, "type": "array" }, "messages": { "items": { "$ref": "#/components/schemas/ResolutionMessageGeneral" }, "type": "array", "title": "Messages" }, "complete": { "type": "boolean", "title": "Complete" } }, "type": "object", "required": [ "page", "url", "messages", "complete" ], "title": "CatalogPage", "example": { "attr_path": "foo.bar.curl", "description": "A very nice Item", "license": "foo", "locked_url": "git:git?rev=xyz", "name": "curl", "outputs": "{}", "outputs_to_install": "{}", "pname": "curl", "rev": "xyz", "rev_count": 4, "rev_date": 0, "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux", "version": "1.0" } }, "CatalogPage-Output": { "properties": { "page": { "type": "integer", "title": "Page" }, "url": { "type": "string", "title": "Url" }, "packages": { "title": "Packages", "nullable": true, "items": { "$ref": "#/components/schemas/ResolvedPackageDescriptor" }, "type": "array" }, "messages": { "items": { "$ref": "#/components/schemas/ResolutionMessageGeneral" }, "type": "array", "title": "Messages" }, "complete": { "type": "boolean", "title": "Complete" } }, "type": "object", "required": [ "page", "url", "messages", "complete" ], "title": "CatalogPage", "example": { "attr_path": "foo.bar.curl", "description": "A very nice Item", "license": "foo", "locked_url": "git:git?rev=xyz", "name": "curl", "outputs": "{}", "outputs_to_install": "{}", "pname": "curl", "rev": "xyz", "rev_count": 4, "rev_date": 0, "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux", "version": "1.0" } }, "CatalogStatus": { "properties": { "catalogs": { "items": { "type": "string" }, "type": "array", "title": "Catalogs" }, "systems": { "items": { "type": "string" }, "type": "array", "title": "Systems" }, "pages_ct": { "type": "integer", "title": "Pages Ct" }, "latest_rev": { "type": "string", "format": "date-time", "title": "Latest Rev" }, "latest_scrape": { "type": "string", "format": "date-time", "title": "Latest Scrape" }, "attribute_path_ct": { "type": "integer", "title": "Attribute Path Ct" }, "search_index_ct": { "type": "integer", "title": "Search Index Ct" }, "derivations_ct": { "type": "integer", "title": "Derivations Ct" }, "schema_version": { "type": "string", "title": "Schema Version" }, "tags": { "additionalProperties": { "items": { "type": "string" }, "type": "array" }, "type": "object", "title": "Tags" } }, "type": "object", "required": [ "catalogs", "systems", "pages_ct", "latest_rev", "latest_scrape", "attribute_path_ct", "search_index_ct", "derivations_ct", "schema_version", "tags" ], "title": "CatalogStatus" }, "ErrorResponse": { "properties": { "detail": { "type": "string", "title": "Detail" } }, "type": "object", "required": [ "detail" ], "title": "ErrorResponse" }, "MessageLevel": { "type": "string", "enum": [ "trace", "info", "warning", "error" ], "title": "MessageLevel" }, "MessageType": { "type": "string", "enum": [ "general", "resolution_trace", "attr_path_not_found", "constraints_too_tight", "attr_path_not_found.not_in_catalog", "attr_path_not_found.systems_not_on_same_page", "attr_path_not_found.not_found_for_all_systems" ], "title": "MessageType" }, "Output": { "properties": { "name": { "type": "string", "title": "Name" }, "store_path": { "type": "string", "title": "Store Path" } }, "type": "object", "required": [ "name", "store_path" ], "title": "Output" }, "Outputs": { "items": { "$ref": "#/components/schemas/Output" }, "type": "array", "title": "Outputs" }, "PackageDescriptor": { "properties": { "install_id": { "type": "string", "title": "Install Id" }, "attr_path": { "type": "string", "title": "Attr Path" }, "systems": { "items": { "$ref": "#/components/schemas/SystemEnum" }, "type": "array", "title": "Systems" }, "version": { "title": "Version", "nullable": true, "type": "string" }, "allow_pre_releases": { "title": "Allow Pre Releases", "default": false, "nullable": true, "type": "boolean" }, "allow_unfree": { "title": "Allow Unfree", "default": true, "nullable": true, "type": "boolean" }, "allow_broken": { "title": "Allow Broken", "default": false, "nullable": true, "type": "boolean" }, "allow_insecure": { "title": "Allow Insecure", "default": false, "nullable": true, "type": "boolean" }, "allowed_licenses": { "title": "Allowed Licenses", "nullable": true, "items": { "type": "string" }, "type": "array" }, "derivation": { "title": "Derivation", "nullable": true, "type": "string" } }, "type": "object", "required": [ "install_id", "attr_path", "systems" ], "title": "PackageDescriptor", "example": { "attr_path": "curl", "install_id": "curl", "systems": [ "x86_64-linux" ] } }, "PackageGroup": { "properties": { "name": { "type": "string", "title": "Name" }, "stability": { "title": "Stability", "nullable": true, "type": "string" }, "descriptors": { "items": { "$ref": "#/components/schemas/PackageDescriptor" }, "type": "array", "title": "Descriptors" } }, "type": "object", "required": [ "name", "descriptors" ], "title": "PackageGroup", "example": { "descriptors": [ { "attr_path": "curl", "install_id": "curl", "systems": [ "x86_64-linux" ] }, { "attr_path": "slack", "install_id": "slack", "systems": [ "x86_64-linux" ] }, { "attr_path": "xorg.xeyes", "install_id": "xeyes", "systems": [ "x86_64-linux" ] } ], "name": "test" } }, "PackageGroups": { "properties": { "items": { "items": { "$ref": "#/components/schemas/PackageGroup" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "PackageGroups", "example": { "items": [ { "descriptors": [ { "attr_path": "curl", "install_id": "curl", "systems": [ "x86_64-linux" ] }, { "attr_path": "slack", "install_id": "slack", "systems": [ "x86_64-linux" ] }, { "attr_path": "xorg.xeyes", "install_id": "xeyes", "systems": [ "x86_64-linux" ] } ], "name": "test" } ] } }, "PackageInfoSearch": { "properties": { "attr_path": { "type": "string", "title": "Attr Path" }, "name": { "type": "string", "title": "Name" }, "pname": { "type": "string", "title": "Pname" }, "description": { "title": "Description", "nullable": true, "type": "string" }, "stabilities": { "items": { "type": "string" }, "type": "array", "title": "Stabilities" }, "system": { "$ref": "#/components/schemas/SystemEnum" } }, "type": "object", "required": [ "attr_path", "name", "pname", "description", "stabilities", "system" ], "title": "PackageInfoSearch", "example": { "attr_path": "foo.bar.curl", "description": "A very nice Item", "name": "curl", "pname": "curl", "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux" } }, "PackageResolutionInfo": { "properties": { "catalog": { "title": "Catalog", "nullable": true, "type": "string" }, "attr_path": { "type": "string", "title": "Attr Path" }, "derivation": { "type": "string", "title": "Derivation" }, "name": { "type": "string", "title": "Name" }, "pname": { "type": "string", "title": "Pname" }, "version": { "type": "string", "title": "Version" }, "system": { "$ref": "#/components/schemas/SystemEnum" }, "outputs": { "items": { "$ref": "#/components/schemas/Output" }, "type": "array", "title": "Outputs" }, "outputs_to_install": { "title": "Outputs To Install", "nullable": true, "items": { "type": "string" }, "type": "array" }, "description": { "title": "Description", "nullable": true, "type": "string" }, "license": { "title": "License", "nullable": true, "type": "string" }, "locked_url": { "type": "string", "title": "Locked Url" }, "rev": { "type": "string", "title": "Rev" }, "rev_count": { "type": "integer", "title": "Rev Count" }, "rev_date": { "type": "string", "format": "date-time", "title": "Rev Date" }, "broken": { "title": "Broken", "nullable": true, "type": "boolean" }, "insecure": { "title": "Insecure", "nullable": true, "type": "boolean" }, "unfree": { "title": "Unfree", "nullable": true, "type": "boolean" }, "stabilities": { "title": "Stabilities", "nullable": true, "items": { "type": "string" }, "type": "array" }, "scrape_date": { "type": "string", "format": "date-time", "title": "Scrape Date" } }, "type": "object", "required": [ "attr_path", "derivation", "name", "pname", "version", "system", "outputs", "outputs_to_install", "description", "license", "locked_url", "rev", "rev_count", "rev_date", "broken", "insecure", "unfree", "stabilities", "scrape_date" ], "title": "PackageResolutionInfo" }, "PackageSearchResult-Input": { "properties": { "items": { "items": { "$ref": "#/components/schemas/PackageInfoSearch" }, "type": "array", "title": "Items" }, "total_count": { "type": "integer", "title": "Total Count" } }, "type": "object", "required": [ "items", "total_count" ], "title": "PackageSearchResult", "example": [ { "attr_path": "foo.bar.curl", "description": "A very nice Item", "name": "curl", "pname": "curl", "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux" } ] }, "PackageSearchResult-Output": { "properties": { "items": { "items": { "$ref": "#/components/schemas/PackageInfoSearch" }, "type": "array", "title": "Items" }, "total_count": { "type": "integer", "title": "Total Count" } }, "type": "object", "required": [ "items", "total_count" ], "title": "PackageSearchResult", "example": [ { "attr_path": "foo.bar.curl", "description": "A very nice Item", "name": "curl", "pname": "curl", "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux" } ] }, "PackagesResult-Input": { "properties": { "items": { "items": { "$ref": "#/components/schemas/PackageResolutionInfo" }, "type": "array", "title": "Items" }, "total_count": { "type": "integer", "title": "Total Count" } }, "type": "object", "required": [ "items", "total_count" ], "title": "PackagesResult" }, "PackagesResult-Output": { "properties": { "items": { "items": { "$ref": "#/components/schemas/PackageResolutionInfo" }, "type": "array", "title": "Items" }, "total_count": { "type": "integer", "title": "Total Count" } }, "type": "object", "required": [ "items", "total_count" ], "title": "PackagesResult" }, "ResolutionMessageGeneral": { "properties": { "level": { "$ref": "#/components/schemas/MessageLevel" }, "type": { "$ref": "#/components/schemas/MessageType" }, "message": { "type": "string", "title": "Message" }, "context": { "additionalProperties": { "type": "string" }, "type": "object", "title": "Context" } }, "type": "object", "required": [ "level", "type", "message", "context" ], "title": "ResolutionMessageGeneral" }, "ResolvedPackageDescriptor": { "properties": { "catalog": { "title": "Catalog", "nullable": true, "type": "string" }, "attr_path": { "type": "string", "title": "Attr Path" }, "derivation": { "type": "string", "title": "Derivation" }, "name": { "type": "string", "title": "Name" }, "pname": { "type": "string", "title": "Pname" }, "version": { "type": "string", "title": "Version" }, "system": { "$ref": "#/components/schemas/SystemEnum" }, "outputs": { "items": { "$ref": "#/components/schemas/Output" }, "type": "array", "title": "Outputs" }, "outputs_to_install": { "title": "Outputs To Install", "nullable": true, "items": { "type": "string" }, "type": "array" }, "description": { "title": "Description", "nullable": true, "type": "string" }, "license": { "title": "License", "nullable": true, "type": "string" }, "locked_url": { "type": "string", "title": "Locked Url" }, "rev": { "type": "string", "title": "Rev" }, "rev_count": { "type": "integer", "title": "Rev Count" }, "rev_date": { "type": "string", "format": "date-time", "title": "Rev Date" }, "broken": { "title": "Broken", "nullable": true, "type": "boolean" }, "insecure": { "title": "Insecure", "nullable": true, "type": "boolean" }, "unfree": { "title": "Unfree", "nullable": true, "type": "boolean" }, "stabilities": { "title": "Stabilities", "nullable": true, "items": { "type": "string" }, "type": "array" }, "scrape_date": { "type": "string", "format": "date-time", "title": "Scrape Date" }, "install_id": { "type": "string", "title": "Install Id" } }, "type": "object", "required": [ "attr_path", "derivation", "name", "pname", "version", "system", "outputs", "outputs_to_install", "description", "license", "locked_url", "rev", "rev_count", "rev_date", "broken", "insecure", "unfree", "stabilities", "scrape_date", "install_id" ], "title": "ResolvedPackageDescriptor" }, "ResolvedPackageGroup-Input": { "properties": { "name": { "type": "string", "title": "Name" }, "page": { "nullable": true, "$ref": "#/components/schemas/CatalogPage-Input" }, "messages": { "items": { "$ref": "#/components/schemas/ResolutionMessageGeneral" }, "type": "array", "title": "Messages" } }, "type": "object", "required": [ "name", "messages" ], "title": "ResolvedPackageGroup", "example": { "attr_path": "foo.bar.curl", "description": "A very nice Item", "license": "foo", "locked_url": "git:git?rev=xyz", "name": "curl", "outputs": "{}", "outputs_to_install": "{}", "pname": "curl", "rev": "xyz", "rev_count": 4, "rev_date": 0, "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux", "version": "1.0" } }, "ResolvedPackageGroup-Output": { "properties": { "name": { "type": "string", "title": "Name" }, "page": { "nullable": true, "$ref": "#/components/schemas/CatalogPage-Output" }, "messages": { "items": { "$ref": "#/components/schemas/ResolutionMessageGeneral" }, "type": "array", "title": "Messages" } }, "type": "object", "required": [ "name", "messages" ], "title": "ResolvedPackageGroup", "example": { "attr_path": "foo.bar.curl", "description": "A very nice Item", "license": "foo", "locked_url": "git:git?rev=xyz", "name": "curl", "outputs": "{}", "outputs_to_install": "{}", "pname": "curl", "rev": "xyz", "rev_count": 4, "rev_date": 0, "stabilities": [ "stable", "unstable" ], "system": "x86_64-linux", "version": "1.0" } }, "ResolvedPackageGroups-Input": { "properties": { "items": { "items": { "$ref": "#/components/schemas/ResolvedPackageGroup-Input" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "ResolvedPackageGroups" }, "ResolvedPackageGroups-Output": { "properties": { "items": { "items": { "$ref": "#/components/schemas/ResolvedPackageGroup-Output" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "ResolvedPackageGroups" }, "ServiceStatus-Input": { "properties": { "service_version": { "type": "string", "title": "Service Version" }, "start_tm": { "type": "string", "format": "date-time", "title": "Start Tm" } }, "type": "object", "required": [ "service_version", "start_tm" ], "title": "ServiceStatus" }, "ServiceStatus-Output": { "properties": { "service_version": { "type": "string", "title": "Service Version" }, "start_tm": { "type": "string", "format": "date-time", "title": "Start Tm" }, "uptime_seconds": { "type": "number", "title": "Uptime Seconds", "readOnly": true }, "uptime_pretty": { "type": "string", "title": "Uptime Pretty", "readOnly": true } }, "type": "object", "required": [ "service_version", "start_tm", "uptime_seconds", "uptime_pretty" ], "title": "ServiceStatus" }, "StoreInfo": { "properties": { "url": { "type": "string", "title": "Url" }, "auth_token": { "type": "string", "title": "Auth Token" } }, "type": "object", "required": [ "url", "auth_token" ], "title": "StoreInfo" }, "SystemEnum": { "type": "string", "enum": [ "aarch64-darwin", "aarch64-linux", "x86_64-darwin", "x86_64-linux", "invalid" ], "title": "SystemEnum" }, "UserBuild-Input": { "properties": { "url": { "type": "string", "title": "Url" }, "rev": { "type": "string", "title": "Rev" }, "rev_count": { "type": "integer", "title": "Rev Count" }, "rev_date": { "type": "string", "format": "date-time", "title": "Rev Date" }, "locked_base_catalog_url": { "title": "Locked Base Catalog Url", "nullable": true, "type": "string" }, "derivation": { "$ref": "#/components/schemas/UserDerivation-Input" } }, "type": "object", "required": [ "url", "rev", "rev_count", "rev_date", "derivation" ], "title": "UserBuild", "example": { "derivation": { "description": "A very nice derivation", "drv_path": "foo.bar.curl", "license": "GnuFoo", "name": "mydrv", "outputs": { "bin": "/nix/store/foo" }, "outputs_to_install": [ "bin" ], "pname": "mydrv", "system": "x86_64-linux", "version": "1.0" }, "locked_base_catalog_url": "https://github.com/flox/nixpkgs?rev=99dc8785f6a0adac95f5e2ab05cc2e1bf666d172", "rev": "99dc8785f6a0adac95f5e2ab05cc2e1bf666d172", "rev_count": 1, "rev_date": "2021-09-01T00:00:00", "url": "http://example.com" } }, "UserBuild-Output": { "properties": { "url": { "type": "string", "title": "Url" }, "rev": { "type": "string", "title": "Rev" }, "rev_count": { "type": "integer", "title": "Rev Count" }, "rev_date": { "type": "string", "format": "date-time", "title": "Rev Date" }, "locked_base_catalog_url": { "title": "Locked Base Catalog Url", "nullable": true, "type": "string" }, "derivation": { "$ref": "#/components/schemas/UserDerivation-Output" } }, "type": "object", "required": [ "url", "rev", "rev_count", "rev_date", "derivation" ], "title": "UserBuild", "example": { "derivation": { "description": "A very nice derivation", "drv_path": "foo.bar.curl", "license": "GnuFoo", "name": "mydrv", "outputs": { "bin": "/nix/store/foo" }, "outputs_to_install": [ "bin" ], "pname": "mydrv", "system": "x86_64-linux", "version": "1.0" }, "locked_base_catalog_url": "https://github.com/flox/nixpkgs?rev=99dc8785f6a0adac95f5e2ab05cc2e1bf666d172", "rev": "99dc8785f6a0adac95f5e2ab05cc2e1bf666d172", "rev_count": 1, "rev_date": "2021-09-01T00:00:00", "url": "http://example.com" } }, "UserBuildCreationResponse": { "properties": { "store": { "$ref": "#/components/schemas/StoreInfo" } }, "type": "object", "required": [ "store" ], "title": "UserBuildCreationResponse" }, "UserBuildList-Input": { "properties": { "items": { "items": { "$ref": "#/components/schemas/UserBuild-Input" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "UserBuildList" }, "UserBuildList-Output": { "properties": { "items": { "items": { "$ref": "#/components/schemas/UserBuild-Output" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "UserBuildList" }, "UserCatalog": { "properties": { "id": { "type": "integer", "title": "Id" }, "name": { "type": "string", "title": "Name" }, "created_at": { "type": "string", "format": "date-time", "title": "Created At" }, "owner_handle": { "title": "Owner Handle", "nullable": true, "type": "string" } }, "type": "object", "required": [ "id", "name", "created_at" ], "title": "UserCatalog" }, "UserDerivation-Input": { "properties": { "drv_path": { "type": "string", "title": "Drv Path" }, "system": { "$ref": "#/components/schemas/SystemEnum" }, "name": { "type": "string", "title": "Name" }, "description": { "type": "string", "title": "Description" }, "outputs": { "$ref": "#/components/schemas/Outputs" }, "outputs_to_install": { "title": "Outputs To Install", "nullable": true, "items": { "type": "string" }, "type": "array" }, "pname": { "title": "Pname", "nullable": true, "type": "string" }, "version": { "title": "Version", "nullable": true, "type": "string" }, "license": { "title": "License", "nullable": true, "type": "string" }, "broken": { "title": "Broken", "nullable": true, "type": "boolean" }, "unfree": { "title": "Unfree", "nullable": true, "type": "boolean" } }, "type": "object", "required": [ "drv_path", "system", "name", "description", "outputs" ], "title": "UserDerivation", "example": { "description": "A very nice derivation", "drv_path": "foo.bar.curl", "license": "GnuFoo", "name": "mydrv", "outputs": { "bin": "/nix/store/foo" }, "outputs_to_install": [ "bin" ], "pname": "mydrv", "system": "x86_64-linux", "version": "1.0" } }, "UserDerivation-Output": { "properties": { "drv_path": { "type": "string", "title": "Drv Path" }, "system": { "$ref": "#/components/schemas/SystemEnum" }, "name": { "type": "string", "title": "Name" }, "description": { "type": "string", "title": "Description" }, "outputs": { "$ref": "#/components/schemas/Outputs" }, "outputs_to_install": { "title": "Outputs To Install", "nullable": true, "items": { "type": "string" }, "type": "array" }, "pname": { "title": "Pname", "nullable": true, "type": "string" }, "version": { "title": "Version", "nullable": true, "type": "string" }, "license": { "title": "License", "nullable": true, "type": "string" }, "broken": { "title": "Broken", "nullable": true, "type": "boolean" }, "unfree": { "title": "Unfree", "nullable": true, "type": "boolean" } }, "type": "object", "required": [ "drv_path", "system", "name", "description", "outputs" ], "title": "UserDerivation", "example": { "description": "A very nice derivation", "drv_path": "foo.bar.curl", "license": "GnuFoo", "name": "mydrv", "outputs": { "bin": "/nix/store/foo" }, "outputs_to_install": [ "bin" ], "pname": "mydrv", "system": "x86_64-linux", "version": "1.0" } }, "UserPackage": { "properties": { "catalog": { "type": "string", "title": "Catalog" }, "name": { "type": "string", "title": "Name" }, "original_url": { "type": "string", "title": "Original Url" } }, "type": "object", "required": [ "catalog", "name", "original_url" ], "title": "UserPackage" }, "UserPackageCreate": { "properties": { "original_url": { "type": "string", "title": "Original Url" } }, "type": "object", "required": [ "original_url" ], "title": "UserPackageCreate" }, "UserPackageList": { "properties": { "items": { "items": { "$ref": "#/components/schemas/UserPackage" }, "type": "array", "title": "Items" } }, "type": "object", "required": [ "items" ], "title": "UserPackageList" } }, "securitySchemes": { "HTTPBearer": { "type": "http", "scheme": "bearer" } } } }