hex_api_package (hex_core v0.7.1) View Source
Link to this section Summary
Link to this section Functions
Specs
get(:hex_core.config(), binary()) :: :hex_api.response()
Gets a package.
Examples:
> hex_api_package:get(hex_core:default_config(), <<"package">>). {ok, {200, ..., #{ <<"name">> => <<"package1">>, <<"meta">> => #{ <<"description">> => ..., <<"licenses">> => ..., <<"links">> => ..., <<"maintainers">> => ... }, ..., <<"releases">> => [ #{<<"url">> => ..., <<"version">> => <<"0.5.0">>}], #{<<"url">> => ..., <<"version">> => <<"1.0.0">>}], ... ]}}}
Specs
Searches packages.
Examples:
> hex_api_package:search(hex_core:default_config(), <<"package">>, []). {ok, {200, ..., [ #{<<"name">> => <<"package1">>, ...}, ... ]}}