Ololade
Posts: 0
Joined: Wed Jul 16, 2014 8:24 pm

create new users collection?

the predefined users collection doesn't allow me to use a list service... that service option doesn't show up... is it worth it to create my own users table? how would I do that...? OR can this be done with the collections that i already have...?

My initial plan had been to store usernames and passwords in the first "collection" and link to another collection where I track their answers to questions and point totals for participating... (I need to track "point totals" by individual user as well as point totals for whichever program area they work under.)

These collections, together, would have data that I would put together in order to display a user profile at certain points in time.

I am incredibly frustrated and have looked at all the links available. :( I need someone to explain how to do this in detail please.

Thanks

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

create new users collection?

Hi Ololade,

You could add additional columns to Users collection:
http://devcenter.appery.io/documentat...

Ololade
Posts: 0
Joined: Wed Jul 16, 2014 8:24 pm

create new users collection?

Hi Katya,

Thank you for such a quick response. My issue is that I did that-- but I don't know how to retrieve those data for the 'user profile' since the "list" service doesn't show up as an option for the users collection...

does that make sense?

Ololade
Posts: 0
Joined: Wed Jul 16, 2014 8:24 pm

create new users collection?

Hi Katya,

Thank you for such a quick response. My issue is that I did that-- but I don't know how to retrieve those data for the 'user profile' since the "list" service doesn't show up as an option for the users collection...

does that make sense?

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

create new users collection?

Hi Ololade,

You can use list service for system users collection.

To get this service follow steps below:

1 Create new REST service and give it name "getUsers".

2 Use following settings for the "Settings" tab: http://prntscr.com/43ps4j/direct

pre

Code: Select all

 URL - https://api.appery.io/rest/1/db/users 
 Method - get 
 Data Type - json 
 Settings - your DB settings 

/pre

3 Use following settings for Request tab: http://prntscr.com/43ptav/direct

pre

Code: Select all

 X-Appery-Database-Id - {database_id} 
 X-Appery-Session-Token - you should use here right user sessiong token. 
 where - optional if needs. 

/pre

4 Open Response tab and create response with parameters you need: see example on the screen shot:
http://prntscr.com/43pwc5/direct

Then navigate to "test" tab and then you can test your service:

http://prntscr.com/43pww9/direct

Regards.

RobertJay
Posts: 0
Joined: Fri Jun 15, 2012 1:32 pm

create new users collection?

Yurii, two questions. First, does your approach involve use a "generic service"? Second, does Appery have any plans to simply allow queries and lists to be added as a regular service from the user collection?

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

create new users collection?

Hi Robert,

1 Nope, that's not a Generic service.
Please check following screen shot to see how create this service:
http://prntscr.com/7js1sx/direct

2 Unfortunatly at this time we don't have such information.

Please read here additional information about users api here: https://devcenter.appery.io/documenta...

Regards.

Jack Bua
Posts: 0
Joined: Sun Jun 28, 2015 10:16 pm

create new users collection?

Hi Yurii,
I received the following in my test:

{
"status":400,
"uri":"https://api.appery.io/rest/1/db/users",
"response":{
"code":"DBUQ002",
"description":"database id not specified"
}
}

and have posted about it here:

https://getsatisfaction.com/apperyio/...
could you take a look at this and tell me what you think please?

Thank you.

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

create new users collection?

Hi Jack,

You use " X-Appery-Database-Id" parameter in headers.

But correct is: "X-Appery-Database-Id"

You need to delete whitespace in the beginning on the this parameter name.

Regards.

Jack Bua
Posts: 0
Joined: Sun Jun 28, 2015 10:16 pm

create new users collection?

Thank you Yurii, that fixed my problem.

I have a question about the session token. I grabbed one from a login and placed it into the service. That one will be used every time now. It that ok or do I need to change it to grab each session?

Return to “Issues”