2021-05-20 14:37:53 +02:00
|
|
|
export const backendApiUrlsInDev = {
|
2021-05-20 14:11:30 +02:00
|
|
|
local: 'http://tktest.lan/api/v1',
|
|
|
|
remote: 'http://tktest.lan/api/v1',
|
|
|
|
// remote: 'https://framadate-api.cipherbliss.com/api/v1',
|
|
|
|
};
|
2021-05-20 14:37:53 +02:00
|
|
|
export const apiV1 = {
|
2021-05-20 14:11:30 +02:00
|
|
|
baseHref: 'http://tktest.lan/api/v1',
|
|
|
|
// baseHref: 'https://framadate-api.cipherbliss.com/api/v1',
|
|
|
|
api_new_poll: '/poll/',
|
|
|
|
api_get_poll: '/poll/{id}',
|
|
|
|
api_new_vote_stack: '/poll/{id}/answer',
|
|
|
|
'api_test-mail-poll': '/api/v1/poll/mail/test-mail-poll/{emailChoice}',
|
|
|
|
'app.swagger': '/api/doc.json',
|
|
|
|
};
|
|
|
|
|
|
|
|
export const endpoints = {
|
|
|
|
versionToUse: 'apiV1',
|
|
|
|
version: {
|
|
|
|
apiV1,
|
|
|
|
},
|
|
|
|
baseHref: backendApiUrlsInDev.local,
|
|
|
|
endpoints: {
|
|
|
|
polls: {
|
|
|
|
name: '/poll',
|
|
|
|
choices: {
|
|
|
|
name: '/choices',
|
|
|
|
},
|
|
|
|
comments: {
|
|
|
|
name: '/comments',
|
|
|
|
},
|
|
|
|
slugs: {
|
|
|
|
name: '/slugs',
|
|
|
|
},
|
|
|
|
answers: {
|
|
|
|
name: '/answers',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
users: {
|
2021-05-21 12:31:42 +02:00
|
|
|
find_my_polls: '/api/v1/poll/owner/:email/',
|
2021-05-20 14:11:30 +02:00
|
|
|
name: '/users',
|
|
|
|
polls: {
|
|
|
|
name: '/polls',
|
|
|
|
sendEmail: {
|
|
|
|
name: '/send-email',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|