How to make a simple HTTP POST request to AEM with a HTTP Rest Client, Postman

This method should be used for DEVELOPMENT PURPOSES ONLY!

During development in the AEM author instance, you would like to test your servlet using an HTTP Rest Client such as Postman. When making a POST request on the Rest Client, you will experience 2 errors. An authentication error, and a 403 forbidden error.


What’s Happening?

Firstly, a typical development approach, you will be working on your author developers instance. Your Rest Client is making a POST request on the author instance, http://localhost:4502. You will get an authentication error.

Secondly, your POST request is being filtered and restricted by the “Apache Sling Referrer Filter” and “Adobe Granite CSRF Filter”. By default, the Apache Sling Referrer Filter blocks any incoming POST requests, and the Adobe Granite CSRF Filter blocks any incoming POST requests without the CSRF-Token token in the header.


How to solve this?

We can solve this issue by including basic auth type in Postman, then allowing incoming POST request in the Apache Sling Referrer Filter OSGI configurations, and remove the requirement of the CSRF-Token in the Adobe Granite CSRF Filter OSGI configurations.


Resource – Simple Servlet – https://gist.github.com/sourcedcode/bd1a2c150fabfc4b37857be0f389ac8a#file-simplepostservlet-java


Step 1 : Configure Basic Auth in Postman

Launch Postman, then navigate to the Authentication tab. Ensure type is set to “Basic Auth”, and username and password are set to “admin”; this is the default username and password for the administrator user while developing on the author instance.


Step 2 : Configure Apache Sling Referrer Filter

  1. Enable allow empty
  2. Remove the POST method from filters

In OSGI configurations (http://localhost:4502/system/console/configMgr), locate “Apache Sling Referrer Filter”. Enable the allow empty property, and remove the post method from filters property.





Step 3 : Configure Adobe Granite CSRF Filter

  1. Remove the POST method from filters

In OSGI configurations (http://localhost:4502/system/console/configMgr), locate “Adobe Granite CSRF Filter”. Remove the post method from filters property.





Final Notes

After making configurations to the two OSGI configurations, you should be able to make a POST request from your HTTP REST Client to your AEM instance.

For production, set Apache Sling Referrer Filter and Adobe Granite CSRF Filter settings back to default. Unless if you are giving access to other servers to make POST requests to your AEM application.

Read more about Apache Sling Referrer Filter.





Hello, I am an enthusiastic Adobe Community Advisor and a seasoned Lead AEM Developer. I am currently serving as an AEM Technical Lead at MNPDigital.ca, bringing over a decade of extensive web engineering experience and more than eight years of practical AEM experience to the table. My goal is to give back to the AEM Full Stack Development community by sharing my wealth of knowledge with others. You can connect with me on LinkedIn.

4 thoughts on “How to make a simple HTTP POST request to AEM with a HTTP Rest Client, Postman

  1. Hi Briankasingli,

    I tried to resolve the authentication error by removing POST in the csrf configuration, however i have been told this is not the correct way, and some different solution should be proposed other than changing anything in the configuration file. If you have came across the same situation please help.

    1. Yup that’s right, during development using POSTMAN on local, you would need to configure the Apache Sling Referrer Filter. But in production, your website would be calling itself, so no need for Apache Sling Referrer Filter.

Leave a Reply

Your email address will not be published. Required fields are marked *


Back To Top
xx1toto
xx1totol
Toto Slot
toto slot
xx1toto
toto slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
Toto Slot
toto slot
Slot Qriss
toto slot
Slot Qriss
slot dana
Slot Dana
Slot Dana
slot dana
toto slot
slot gacor
slot pulsa
Slot Dana
slot pulsa
slot pulsa
Situs Toto
situs toto
toto slot
scatter hitam
slot toto
situs toto slot
xx1toto
slot toto
slot toto
Scatter Hitam
Situs toto
Slot Demo
toto slot
Scatter Hitam
bandar togel, situs toto slot
bacan4d
toto slot
Situs Toto Slot
situs slot gacor
situs toto slot
Slot Mahjong
xx1toto
situs slot gacor
Situs Toto
xx1toto
xx1toto, Situs Toto Slot
xx1toto
bacansport
bacan4d
xx1toto, situs toto slot, bandar casino
xx1toto, situs toto slot, bandar casino
xx1toto, situs toto, toto slot
xx1toto, Situs Toto Slot
Link Situs Toto Slot
scatter hitam
xx1toto, situs toto, tabel shio
Situs Scatter Hitam Mahjong Wins 3
xx1toto
xx1toto, situs toto slot, bandar togel
situs toto slot
scatter hitam, black scatter, mahjong wins 3
mahjong scatter
situs toto
black scatter, mahjong wins 3
xx1toto
xx1toto
bacan4d
xx1toto, situs toto
bacansport
bacansport
xx1toto
bacansport
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
slot gacor bacan4d
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
Situs Toto, Toto Slot
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
xx1toto
bacansport
xx1toto
bacan4d
xx1toto
xx1toto
bacan4d login situs toto
situs toto slot
linkbacan4d
bacan4d
bacan4d
bacansports
bacan4dslot gacor<
xx1toto
xx1toto
bacan4d
bacan4d
scatter hitam
xx1toto
xx1toto
xx1toto
bacan4d
bacan4d situs toto macau
bacan4d slot gacor x1000
xx1toto scatter hitam
xx1toto
xx1toto
xx1toto
bacan4d slot gacor 2024
bacansport
Slot Qriss
bacan4d game slot gacor
ts77casino bet 200
bacansport
aplikasi slot
xx1toto scatter hitam
bacan4d login
bacan4d login situs slot gacor
situs toto
xx1toto
xx1toto
bacansport
bacan4d
xx1toto
xx1toto
slottoto
xx1toto
bacan4d login slot gacor
bacan4d slot
ts77casino
ts77casino
ts77casino
ts77casino
Scatter Hitam
Situs Toto
toto slot
Scatter Hitam
Situs Toto
toto slot
bacan4d situs slot toto
scatter hitam
slot mahjong wins 3
mahjong wins 3 black scatter
scatter hitam
ts77casino
ts77casino
tabel shio 2025
bacan4d slot sever thailand
akun slot bet 400
bacan4d slot gacor toto
instagram bacansports
situs toto
bacan4d slot toto
scatter hitam
Situs Toto
scatter hitam
slot bet kecil
bacansports taruhan bola
taruhan bola
facebook bacan4d
Demo Slot
Situs Toto
toto togel
Toto slot gacor
slot gacor bett 200
situs toto
situs toto
bacan4d situs toto 176
bacan4d slot toto 2025
bacansport
bacantogel
situs slot toto
Situs Toto Slot
Bacansports
Bacantoto Situs Toto Slot
xx1toto
xx1toto
xx1toto, situs toto slot
bacan4d
Situs Toto Slot, Situs Togel, toto slot, xx1toto
scatter hitam
Situs Toto Slot, Bandar Togel, Toto macau
Slot Toto
xx1toto, Login Situs Toto
xx1toto, Situs Toto Slot
Situs Toto Slot, Agen Toto Slot 4D, Tabel Shio
xx1toto, situs toto, toto slot, bandar togel
xx1toto, situs black scatter hitam
Situs Toto Slot, Bandar Togel
xx1toto, situs toto
Situs Toto Slot
Situs Toto Slot
Slot Toto
situs toto slot
bacan4d situs idn slot
bacansports
situs toto slot
bacansport
situs toto slot
situs slot terbaru
agen toto, situs toto
situs toto slot
situs toto slot
situs toto slot
bacan4d
bacan4d
bacan4d
situs toto slot
situs toto slot
Slot Mahjong, Scatter Hitam
xx1toto, situs toto slot
situs toto
situs toto
bandar togel, situs toto slot
toto slot
Bacan4d Login Situs Slot Toto
Bacan4d Login Toto Slot
Bacan4d Situs Toto Slot
Link Alternatif Bacan4d Situs Toto Slot
Bacan4d Slot Gacor
Bacan4d Slot Bet 400
Bacantoto Situs Slot
BACANTOTO Situs Toto
toto slot
bacansport
Toto Slot
Bacan4d login
Slot Toto
BACANSPORTS | Slot Gacor Games
Slot Dana
Slot Toto
bacansport
Slot toto
bacansport
bacansport
bacansport
bacansport
bacansport
Bacan4d Link Alternatif
Bacan4d Rtp Slot
bacan4d
ts77casino
taruhan bola
ubobet bola
bacansport
situs taruhan bola indonesia
situs taruhan bola
Login Toto
taruhan bola
judi bola
taruhan bola
bacan4d
toto slot
bacan4d promo
bacantoto casino slot
bacansport
Bacansports Piala Dunia 2026
bacan4d daftar
bacan4d
bacansport
Slot Dana
bacansports
bacansports
Bacan4d Toto
bacansports
slot dana
Slot Bola
bacantogel
bacantogel
slot toto
bacansports
bacansport
slot dana
taruhan bola
bacansports
slot dana