### Install ReceiptDecoder Elixir Package Source: https://github.com/linjunpop/receipt_decoder/blob/master/README.md This snippet demonstrates how to add the `receipt_decoder` package as a dependency in an Elixir project's `mix.exs` file. Including this line in the `deps` function ensures that the package is fetched and compiled when `mix deps.get` is run, making its functionalities available to your application. ```Elixir def deps do [ {:receipt_decoder, "~> 0.7.0"} ] end ``` -------------------------------- ### Compile ASN.1 to Erlang Modules for ReceiptDecoder Development Source: https://github.com/linjunpop/receipt_decoder/blob/master/README.md This command is used during the development of the `receipt_decoder` package to compile the ASN.1 definition file (`ReceiptModule.asn1`) into Erlang modules. This compilation step is crucial for the package's internal parsing mechanism, which relies on these modules to interpret the binary structure of iOS receipts. ```Elixir $ mix receipt_decoder.compile_asn1 ``` -------------------------------- ### Decode iOS App Receipt in Elixir Source: https://github.com/linjunpop/receipt_decoder/blob/master/README.md This Elixir code illustrates the primary usage of the `receipt_decoder` package: decoding a Base64 encoded iOS App Store receipt. The `ReceiptDecoder.decode/1` function processes the input string and returns a tuple, typically `{:ok, %ReceiptDecoder.AppReceipt{...}}`, containing the parsed receipt data as a structured map. ```Elixir ReceiptDecoder.decode(BASE64_ENCODED_RECEIPT) # {:ok, %ReceiptDecoder.AppReceipt{...}} ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.