Skip to content

Instantly share code, notes, and snippets.

@zeddee
Last active August 8, 2019 08:46
Show Gist options
  • Save zeddee/40ad99bc427f095a32b520a9aa0a651d to your computer and use it in GitHub Desktop.
Save zeddee/40ad99bc427f095a32b520a9aa0a651d to your computer and use it in GitHub Desktop.

Adyen Notes

General API docs notes

Adyen POST idempotency

  • Adyen's POST endpoints "support" idempotency.
  • Wording is vague on https://docs.adyen.com/development-resources/api-idempotency, but I gather that:
    • Adyen's POST endpoints do not perform idempotent actions out-of-the-box.
    • To make POST requests idempotent, you must send the POST request with a "Idempotency-Key:<key>" header, where <key> is a user-defined string of up to 64 chars. Each (The docs recommend using a UUID of sorts).
  • If the resource for the POST request already exists, the Adyen servers will return a response for the first attempt at the POST request.
  • An idempotent POST request returns a response with the same "Idempotency-Key" header.
  • The value of <key> is stored at a company account level.
  • docs say that <key> must be unique to the company account, but what this means is not clear. Does "unique to company account" mean that:
    • Each request must use a unique key? But the scope of that key is only within the company account, and only needs to be unique within the company account?
    • Each API-KEY (and therefore, user account) must use a unique key, and that uniqueness is scoped only within the company account?
    • Each key must be unique throughout Adyen? Which means the scope of this API mechanism is ridiculously large?
    • Each company must use a single unique key?
    • Unclear.
  • docs say that <key> is valid for a minimum of 31 days.
    • This is weird, because TTL is usually a specific period, no min or max.
    • Doesn't say how to control the expiration period.
    • Doesn't mention a way to designate a <key> as expired.
    • So does this mean that the expiration of the keys depend on when the key was last used? And has some sort of exponential backoff mechanism to decide the next expiration date?
    • Or that each time a key is used, it's TTL is reset to 31 days?

PSD 2/ Directive (EU) 2015/2366-specific docs

Third-party PSD 2 docs

Europa.eu docs

Resources

Glossary

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment