henry3260 commented on code in PR #68854:
URL: https://github.com/apache/airflow/pull/68854#discussion_r4338725406


##########
airflow-core/src/airflow/api_fastapi/core_api/datamodels/providers.py:
##########
@@ -34,3 +36,140 @@ class ProviderCollectionResponse(BaseModel):
 
     providers: list[ProviderResponse]
     total_entries: int
+
+
+# The models below mirror the provider metadata structure defined in
+# airflow-core/src/airflow/provider_info.schema.json (deprecated keys 
excluded). Keys the
+# models do not declare are dropped from the response, so new metadata keys 
need a field here.
+
+
+class ProviderIntegrationInfo(BaseModel):
+    """Integration provided by a provider."""
+
+    integration_name: str = Field(alias="integration-name")
+    external_doc_url: str | None = Field(None, alias="external-doc-url")
+    how_to_guide: list[str] | None = Field(None, alias="how-to-guide")
+    logo: str | None = None
+    tags: list[str] | None = None
+
+
+class ProviderIntegrationModulesInfo(BaseModel):
+    """Python modules an integration contributes for one kind of 
functionality."""
+
+    integration_name: str = Field(alias="integration-name")
+    python_modules: list[str] = Field(alias="python-modules")
+
+
+class ProviderAssetUriInfo(BaseModel):
+    """Asset URI scheme handling provided by a provider."""
+
+    schemes: list[str]
+    handler: str | None = None
+    factory: str | None = None
+    to_openlineage_converter: str | None = None
+
+
+class ProviderDialectInfo(BaseModel):
+    """SQL dialect provided by a provider."""
+
+    dialect_type: str | None = Field(None, alias="dialect-type")
+    dialect_class_name: str | None = Field(None, alias="dialect-class-name")
+
+
+class ProviderTransferInfo(BaseModel):
+    """Transfer operator provided by a provider."""
+
+    source_integration_name: str = Field(alias="source-integration-name")
+    target_integration_name: str = Field(alias="target-integration-name")
+    python_module: str = Field(alias="python-module")
+    how_to_guide: str | None = Field(None, alias="how-to-guide")
+
+
+class ProviderConnectionTypeInfo(BaseModel):
+    """Connection type provided by a provider."""
+
+    connection_type: str = Field(alias="connection-type")
+    hook_class_name: str = Field(alias="hook-class-name")
+    hook_name: str | None = Field(None, alias="hook-name")

Review Comment:
   sure



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to