Paapi5
A minimalistic Elixir library for the Amazon Product Advertising Api version 5
Install / Use
/learn @dallagi/Paapi5README
Paapi5
A minimalistic Elixir library for the Amazon Product Advertising Api version 5.
Installation
This package can be installed by adding paapi5 to your list of dependencies in mix.exs:
def deps do
[
{:paapi5, "~> 1.0.0"}
]
end
Usage
Build a signed request for the Amazon Product Advertising API 5 (PAAPI5):
request =
Paapi5.request(
"<access_key>",
"<secret_key>",
"<partner_tag>",
:us,
"SearchItems",
%{"Keywords" => "elixir in action"}
)
You can then use a HTTP client of your choice to actually send this request, e.g.:
items = HTTPoison.request!(request.method, request.url, request.body, request.headers)
The marketplace can either be an atom (e.g., :us, :it, :uk, etc.) or a Paapi5.Marketplace struct
with the host and region (e.g., %Paapi5.Marketplace{host: "webservices.amazon.it", region: "eu-west-1"}).
The known marketplaces are :au, :br, :ca, :fr, :de, :in, :it, :jp, :mx, :nl, :sg, :sa, :es, :se, :tr, :ae, :uk, :us.
For a reference about operations and their parameters, see the PAAPI5 documentation.
For working examples on usage of this library, see the tests.
Development
Issues and contributions are very welcome!
To launch tests, run:
mix test
Tests require a valid set of credentials for the Italian PAAPI to be passed via environment variables:
export ACCESS_KEY="your-paapi-access-key"
export SECRET_KEY="your-paapi-secret-key"
export PARTNER_TAG="your-paapi-partner-tag"
Related Skills
node-connect
345.4kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
104.6kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
345.4kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
345.4kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
