Expand description
SDK parsing for cloud provider definitions
This crate handles parsing of various cloud provider SDK definitions
into an intermediate representation (ServiceDefinition).
§Parsing Strategy
§Spec-Based Parsing (Recommended)
- AWS: Parse Smithy JSON AST from github.com/aws/api-models-aws
- Kubernetes: Parse OpenAPI 3.0 specs from API server
- GCP: Parse Discovery Documents from googleapis.com or gRPC FileDescriptorSet
- Azure: Parse OpenAPI specs from github.com/Azure/azure-rest-api-specs
- gRPC: Parse Protocol Buffer FileDescriptorSet from .proto files or gRPC reflection
§Legacy Parsing
For AWS SDK for Rust, we parse the published crate structure:
operation::*modules contain Input/Output types for each operationtypes::*module contains data types used by operations
Operations are grouped by resource and mapped to CRUD:
- CreateX, PutX → Create
- GetX, DescribeX, HeadX → Read
- UpdateX, ModifyX, PutX → Update
- DeleteX, RemoveX → Delete
Re-exports§
pub use discovery::DiscoveryParser;pub use openapi::OpenApiParser;pub use protobuf::ProtobufParser;pub use smithy::SmithyParser;
Modules§
- discovery
- Google Discovery Document parser
- openapi
- OpenAPI 3.0 specification parser
- protobuf
- Protobuf/gRPC service parser
- smithy
- Smithy specification parser
Structs§
- AwsParser
- AWS SDK parser
- Operation
Classifier - Classifies SDK operations into CRUD operations
- Rustdoc
Loader - Loads rustdoc JSON from a file path
- Type
Mapper - Maps SDK type names to FieldType
Enums§
- Crud
Operation - CRUD operation types
Functions§
- parse_
aws_ service - Parse AWS SDK service from metadata