Naming rules shared by the generator plugins.
The Apify API uses camelCase for fields and parameters, kebab-case for path
segments and a few UPPER_SNAKE keys (usage services, run status counts). The
generated client uses snake_case everywhere and keeps the original names only
where they go over the wire.
Generation-time only
Runs under mix apify.gen only; lives in dev/ because the plugins depend on
the dev-only :oapi_generator.
Summary
Functions
Converts a path segment to a module name segment.
Converts an API name to snake_case.
Maps each name to its snake_case form, raising if two names collide.
Functions
Converts a path segment to a module name segment.
iex> camel("key-value-stores")
"KeyValueStores"
Converts an API name to snake_case.
iex> snake("defaultDatasetId")
"default_dataset_id"
iex> snake("isPPEPlatformUsagePaidByUser")
"is_ppe_platform_usage_paid_by_user"
iex> snake("publicActorRunStats30Days")
"public_actor_run_stats30_days"
iex> snake("TIMED-OUT")
"timed_out"
iex> snake("_id")
"_id"
Maps each name to its snake_case form, raising if two names collide.