function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Caleb Kuester 35Caleb Kuester 35 

Public Endpoint (Webhook) questions

Hi!

I have created a webhook listener, but it seems that I see an "under construction" page instead of anything I might otherwise expect.

In sites, I have a URL created and it is active. There is also a visualforce page created to use as its active site home page. If I go to that site explicitly, via the URL link, it gives me the markup for that visualforce page.

Great.

The problem is that, in order for me to be able to use it, the url must be in the format of: org_url/services/apexrest/urlMapping. So that would be https://caleb-xxxxxxx.cs70.force.com/services/apexrest/urlmappingvalue

The site user has access to the Apex class and Visualforce page.

When I go to workbench's REST Explorer tool, it gives me exactly what I need, presumably because I'm authenticated into my org, but when I use the URL listed above, it says the site is  under construction.

My @HttpPost method returns some garbage string (intentionally) and that string is only returned in workbench.

I'm curious what I'm missing.

 

AnudeepAnudeep (Salesforce Developers) 
Hi Caleb - I recommend following the steps listed in this help article if not done already

 
Caleb Kuester 35Caleb Kuester 35
I found out what I did wrong. I didn't use the full URL from the site.
xxxxxxx.cs70.force.com/services/apexrest/urlmappingvalue was supposed to be xxxxxxx.cs70.force.com/urlmappingvalue/services/apexrest/urlmappingvalue (because of how I named the site stuff)