Opened 3 years ago

Closed 15 months ago

#12075 closed Bug/Something is broken (fixed)

Control Panel REST UI returns a 500 error

Reported by: takethestreets Owned by: Jamie McClelland
Priority: Medium Component: Tech
Keywords: red, REST Cc:
Sensitive: no

Description

Hi all,

I'm trying to implement the instructions listed here for the Red REST UI: https://support.mayfirst.org/wiki/control-panel/alternative-interfaces

Using the URL "https://members.mayfirst.org/cp" yields a 301 error, and suggests "https://members.mayfirst.org/cp/" (with a trailing slash). However, "https://members.mayfirst.org/cp/" and "https://members.mayfirst.org/cp/index.php" only seem to give 500 errors.

Questions:

  • Does the REST API still work?
  • The names of the POST fields for username and password aren't clear from the documentation, how should I pass them?

Change History (8)

comment:1 Changed 3 years ago by JaimeV

Owner: set to Jamie McClelland
Status: newassigned

I think we'll need jamie's help wth that. Have you tried using the red-cli interface as an alternative?

comment:2 Changed 3 years ago by takethestreets

Hi Jaime,

I don't have access to the red-cli, nor would it matter if I did. My use case here is using Ansible to generate dev and test sites for my clients. I can provision them on non-MFPL hardware - but my DNS hosting is with MFPL, so I need to be able to call the REST API to define their CNAMEs.

comment:3 Changed 3 years ago by Jamie McClelland

Thanks for the tip on the missing documentation about logins - I just updated the docs (the parameters are: user_name and user_pass).

However, it still won't work because I have invoked IP based clear listing since I was the only one using this and I wanted added security while it was being tested.

Are you executing these commands from a static IP address? If so, let me know the IP and I can add it to the white list. If it's a dynamic IP - I can also lift the restriction (since this has been in development long enough for me to have more confidence in it's use).

jamie

comment:4 Changed 3 years ago by Jessie Rose Lee

Hey Jamie,

We are not executing commands from a static IP at the time. If you feel comfortable lifting the restriction that would be great!

~Jessie

comment:5 Changed 3 years ago by Jamie McClelland

Resolution: fixed
Status: assignedclosed

Ok, restriction lifted. Please let us know how it goes.

comment:6 Changed 15 months ago by takethestreets

Resolution: fixed
Status: closedassigned

I'm still getting an 500 error here. Was the restriction re-instituted?

comment:7 Changed 15 months ago by Jamie McClelland

Can you copy and paste the code you are using (without the passwords)?

I noticed that the documentation incorrectly specified the API url as https://members.mayfirst.org/cp instead of https://members.mayfirst.org/cp/api.php (now fixed). Could that be the problem?

jamie

comment:8 Changed 15 months ago by takethestreets

Resolution: fixed
Status: assignedclosed

That was exactly the problem Jamie. It looks good now, thanks!

Please login to add comments to this ticket.

Note: See TracTickets for help on using tickets.