mirror of
https://github.com/OneUptime/oneuptime.git
synced 2026-04-06 00:32:12 +02:00
fix status page url
This commit is contained in:
@@ -50,7 +50,7 @@
|
||||
var bubble = 'all';
|
||||
var statusMessage = '';
|
||||
var url =
|
||||
'https://staging.oneuptime.com/api/statusPage/statusBubble?statusPageId=5ffa98e25f166c0014d9c045&statusBubbleId=04013896-dcbe-40bd-8f1d-f4825badd782';
|
||||
'https://staging.oneuptime.com/api/status-page/statusBubble?statusPageId=5ffa98e25f166c0014d9c045&statusBubbleId=04013896-dcbe-40bd-8f1d-f4825badd782';
|
||||
fetch(url, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/</span>
|
||||
<span>https://oneuptime.com/api/status-page/</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -45,7 +45,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -256,7 +256,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354</p>
|
||||
|
||||
<p>Request Body</p>
|
||||
<pre>
|
||||
@@ -352,7 +352,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/dashboard</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/dashboard</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -427,7 +427,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/dashboard?skip=0&limit=5</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/dashboard?skip=0&limit=5</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -597,7 +597,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/statuspage</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/statuspage</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -672,7 +672,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/statuspage?skip=0&limit=5</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/statuspage?skip=0&limit=5</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -843,7 +843,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/statuspages</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/statuspages</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -881,7 +881,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/statuspages</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/statuspages</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1062,7 +1062,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:statusPageId</span>
|
||||
<span>https://oneuptime.com/api/status-page/:statusPageId</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1122,7 +1122,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e3bfa83de29ed659247259d</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e3bfa83de29ed659247259d</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1211,7 +1211,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1422,7 +1422,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354</p>
|
||||
|
||||
<p>Request Body</p>
|
||||
<pre>
|
||||
@@ -1540,7 +1540,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:statusPageId</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:statusPageId</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1593,7 +1593,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/5e3bfa83de29ed659247259d</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/5e3bfa83de29ed659247259d</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1705,7 +1705,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:statusPageId/rss</span>
|
||||
<span>https://oneuptime.com/api/status-page/:statusPageId/rss</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1765,7 +1765,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e3bfa83de29ed659247259d/rss</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e3bfa83de29ed659247259d/rss</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1780,7 +1780,7 @@
|
||||
<rss version="2.0">
|
||||
<Title>Incidents for status page Zenith</Title>
|
||||
<Description>RSS feed for all incidents related to monitors attached to status page</Description>
|
||||
<Link>http://localhost:3002/statusPage/rss</Link>
|
||||
<Link>http://localhost:3002/status-page/rss</Link>
|
||||
<LastBuildDate>Thu Feb 06 2020 12:44:44 GMT+0100 (West Africa Standard Time)</LastBuildDate>
|
||||
<Language>en</Language>
|
||||
<Incidents>
|
||||
@@ -1899,7 +1899,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:statusPageId/notes</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:statusPageId/notes</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1990,7 +1990,7 @@
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">
|
||||
https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/5e3bfa83de29ed659247259d/notes?skip=0&limit=5</p>
|
||||
https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/5e3bfa83de29ed659247259d/notes?skip=0&limit=5</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -2243,7 +2243,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:monitorId/individualnotes</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:monitorId/individualnotes</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2334,7 +2334,7 @@
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">
|
||||
https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/5e321f87542c6f61d1292a83/individualnotes?skip=0&limit=5
|
||||
https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/5e321f87542c6f61d1292a83/individualnotes?skip=0&limit=5
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2428,7 +2428,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:statusPageId/events</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:statusPageId/events</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2519,7 +2519,7 @@
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">
|
||||
https://oneuptime.com/api/statusPage/5e8cda4eac92233bf1e4645a/5e8cdb19ac92233bf1e464d6/events?skip=0&limit=5</p>
|
||||
https://oneuptime.com/api/status-page/5e8cda4eac92233bf1e4645a/5e8cdb19ac92233bf1e464d6/events?skip=0&limit=5</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -2666,7 +2666,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:monitorId/individualevents</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:monitorId/individualevents</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2742,7 +2742,7 @@
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">
|
||||
https://oneuptime.com/api/statusPage/5e8cda4eac92233bf1e4645a/5e8cdaebac92233bf1e4649a/individualevents?date=2020-04-09T21:22:08.845Z
|
||||
https://oneuptime.com/api/status-page/5e8cda4eac92233bf1e4645a/5e8cdaebac92233bf1e4649a/individualevents?date=2020-04-09T21:22:08.845Z
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2888,7 +2888,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/:monitorId/monitorStatuses</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/:monitorId/monitorStatuses</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2979,7 +2979,7 @@
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">
|
||||
https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354d/5e321f87542c6f61d1292a83/monitorStatuses</p>
|
||||
https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354d/5e321f87542c6f61d1292a83/monitorStatuses</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -3044,7 +3044,7 @@
|
||||
<div class="cf-grid-row">
|
||||
<div class="col-full">
|
||||
<div class="item-title">
|
||||
<span>https://oneuptime.com/api/statusPage/:projectId/probes</span>
|
||||
<span>https://oneuptime.com/api/status-page/:projectId/probes</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -3119,7 +3119,7 @@
|
||||
|
||||
<div class="example-code example-response">
|
||||
<p>Request URL</p>
|
||||
<p class="url">https://oneuptime.com/api/statusPage/5e2ecf45516aae26b133f354/probes?skip=0&limit=5</p>
|
||||
<p class="url">https://oneuptime.com/api/status-page/5e2ecf45516aae26b133f354/probes?skip=0&limit=5</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -994,7 +994,7 @@ router.get('/:statusPageId/rss', checkUser, async function(req, res) {
|
||||
refinedIncidents.push({
|
||||
item: {
|
||||
title: incident.title,
|
||||
guid: `${global.apiHost}/statusPage/${statusPageId}/rss/${incident._id}`,
|
||||
guid: `${global.apiHost}/status-page/${statusPageId}/rss/${incident._id}`,
|
||||
pubDate: new Date(incident.createdAt).toUTCString(),
|
||||
description: `<![CDATA[Description: ${
|
||||
incident.description
|
||||
@@ -1032,7 +1032,7 @@ router.get('/:statusPageId/rss', checkUser, async function(req, res) {
|
||||
'RSS feed for all incidents related to monitors attached to status page',
|
||||
},
|
||||
{
|
||||
link: `${global.apiHost}/statusPage/${statusPageId}/rss`,
|
||||
link: `${global.apiHost}/status-page/${statusPageId}/rss`,
|
||||
},
|
||||
{
|
||||
lastBuildDate: () => new Date().toUTCString(),
|
||||
@@ -1632,7 +1632,7 @@ router.get('/:projectId/monitor/:statusPageId', checkUser, async function(
|
||||
});
|
||||
|
||||
router.post(
|
||||
'/:projectId/createExternalStatusPage/:statusPageId',
|
||||
'/:projectId/createExternalstatus-page/:statusPageId',
|
||||
checkUser,
|
||||
async function(req, res) {
|
||||
try {
|
||||
@@ -1740,7 +1740,7 @@ router.post(
|
||||
);
|
||||
|
||||
router.post(
|
||||
'/:projectId/updateExternalStatusPage/:externalStatusPageId',
|
||||
'/:projectId/updateExternalstatus-page/:externalStatusPageId',
|
||||
checkUser,
|
||||
async function(req, res) {
|
||||
try {
|
||||
@@ -1863,7 +1863,7 @@ router.get(
|
||||
);
|
||||
|
||||
router.post(
|
||||
'/:projectId/deleteExternalStatusPage/:externalStatusPageId',
|
||||
'/:projectId/deleteExternalstatus-page/:externalStatusPageId',
|
||||
checkUser,
|
||||
async function(req, res) {
|
||||
try {
|
||||
|
||||
@@ -143,7 +143,7 @@ describe('Status API', function() {
|
||||
it('should not add status page if the page name is missing', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.post(`/statusPage/${projectId}`)
|
||||
.post(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
links: [],
|
||||
@@ -162,7 +162,7 @@ describe('Status API', function() {
|
||||
it('should add status page', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.post(`/statusPage/${projectId}`)
|
||||
.post(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
name: 'Status Page',
|
||||
@@ -197,7 +197,7 @@ describe('Status API', function() {
|
||||
it('should add private status page', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.post(`/statusPage/${projectId}`)
|
||||
.post(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
name: 'Private Status Page',
|
||||
@@ -235,7 +235,7 @@ describe('Status API', function() {
|
||||
it('should get private status page for authorized user', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(`/statusPage/${privateStatusPageId}`)
|
||||
.get(`/status-page/${privateStatusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -248,7 +248,7 @@ describe('Status API', function() {
|
||||
it('should get valid private status page rss for authorized user', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(`/statusPage/${privateStatusPageId}/rss`)
|
||||
.get(`/status-page/${privateStatusPageId}/rss`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -259,7 +259,7 @@ describe('Status API', function() {
|
||||
|
||||
it('should not get private status page for unauthorized user', function(done) {
|
||||
request
|
||||
.get(`/statusPage/${privateStatusPageId}`)
|
||||
.get(`/status-page/${privateStatusPageId}`)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
expect(res).to.have.status(401);
|
||||
@@ -270,7 +270,7 @@ describe('Status API', function() {
|
||||
it('should not update status page settings when domain is not string', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
domain: 5,
|
||||
@@ -285,7 +285,7 @@ describe('Status API', function() {
|
||||
it('should not update status page settings when domain is not valid', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
domain: 'wwwtest',
|
||||
@@ -300,7 +300,7 @@ describe('Status API', function() {
|
||||
it('should update status page settings', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.put(`/statusPage/${projectId}`)
|
||||
.put(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
_id: statusPageId,
|
||||
@@ -334,7 +334,7 @@ describe('Status API', function() {
|
||||
it('should return monitor category with monitors in status page data', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(`/statusPage/${statusPageId}`)
|
||||
.get(`/status-page/${statusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send()
|
||||
.end(function(err, res) {
|
||||
@@ -358,7 +358,7 @@ describe('Status API', function() {
|
||||
it('should get list of scheduled events', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(`/statusPage/${projectId}/${statusPageId}/events`)
|
||||
.get(`/status-page/${projectId}/${statusPageId}/events`)
|
||||
.set('Authorization', authorization)
|
||||
.send()
|
||||
.end(function(err, res) {
|
||||
@@ -378,7 +378,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(
|
||||
`/statusPage/${projectId}/${monitorId}/individualevents?date=${today}`
|
||||
`/status-page/${projectId}/${monitorId}/individualevents?date=${today}`
|
||||
)
|
||||
.set('Authorization', authorization)
|
||||
.send()
|
||||
@@ -407,7 +407,7 @@ describe('Status API', function() {
|
||||
})
|
||||
.then(() => {
|
||||
request
|
||||
.post(`/statusPage/${projectId}/${monitorId}/monitorLogs`)
|
||||
.post(`/status-page/${projectId}/${monitorId}/monitorLogs`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
responseTime: true,
|
||||
@@ -427,7 +427,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'oneuptimeapp.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -441,7 +441,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'status.oneuptimeapp.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -479,7 +479,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'status.x.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -492,7 +492,7 @@ describe('Status API', function() {
|
||||
{ verified: true }
|
||||
).then(function() {
|
||||
request
|
||||
.get(`/statusPage/null?url=${domain}`)
|
||||
.get(`/status-page/null?url=${domain}`)
|
||||
.send()
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -508,7 +508,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'status.y.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -516,7 +516,7 @@ describe('Status API', function() {
|
||||
expect(res).to.have.status(200);
|
||||
const domain = 'status.y.com';
|
||||
request
|
||||
.get(`/statusPage/null?url=${domain}`)
|
||||
.get(`/status-page/null?url=${domain}`)
|
||||
.send()
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -585,7 +585,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'status.oneuptime.hackerbay' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -606,7 +606,7 @@ describe('Status API', function() {
|
||||
],
|
||||
};
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -627,7 +627,7 @@ describe('Status API', function() {
|
||||
],
|
||||
};
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -641,7 +641,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'oneuptime.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -655,7 +655,7 @@ describe('Status API', function() {
|
||||
const authorization = `Basic ${token}`;
|
||||
const data = { domain: 'status.oneuptimeapp.com' };
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/domain`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/domain`)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
.end(function(err, res) {
|
||||
@@ -678,7 +678,7 @@ describe('Status API', function() {
|
||||
if (err) throw err;
|
||||
const newProjectId = res.body._id;
|
||||
request
|
||||
.post(`/statusPage/${newProjectId}`)
|
||||
.post(`/status-page/${newProjectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
name: 'Status Page name',
|
||||
@@ -694,7 +694,7 @@ describe('Status API', function() {
|
||||
const newStatusPageId = res.body._id;
|
||||
request
|
||||
.put(
|
||||
`/statusPage/${newProjectId}/${newStatusPageId}/domain`
|
||||
`/status-page/${newProjectId}/${newStatusPageId}/domain`
|
||||
)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
@@ -724,7 +724,7 @@ describe('Status API', function() {
|
||||
if (err) throw err;
|
||||
const newProjectId = res.body._id;
|
||||
request
|
||||
.post(`/statusPage/${newProjectId}`)
|
||||
.post(`/status-page/${newProjectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
name: 'Status Page name',
|
||||
@@ -740,7 +740,7 @@ describe('Status API', function() {
|
||||
const newStatusPageId = res.body._id;
|
||||
request
|
||||
.put(
|
||||
`/statusPage/${newProjectId}/${newStatusPageId}/domain`
|
||||
`/status-page/${newProjectId}/${newStatusPageId}/domain`
|
||||
)
|
||||
.set('Authorization', authorization)
|
||||
.send(data)
|
||||
@@ -768,7 +768,7 @@ describe('Status API', function() {
|
||||
// select the first domain
|
||||
const { _id: domainId } = statusPage.domains[0];
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.send(data)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
@@ -787,7 +787,7 @@ describe('Status API', function() {
|
||||
// select the first domain
|
||||
const { _id: domainId } = statusPage.domains[0];
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.send(data)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
@@ -806,7 +806,7 @@ describe('Status API', function() {
|
||||
// select the first domain
|
||||
const { _id: domainId } = statusPage.domains[0];
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.send(data)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
@@ -827,7 +827,7 @@ describe('Status API', function() {
|
||||
// provide a random object id
|
||||
const statusPageId = '5ea70eb4be9f4b177a1719ad';
|
||||
request
|
||||
.put(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.put(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.send(data)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
@@ -844,7 +844,7 @@ describe('Status API', function() {
|
||||
// select the first domain
|
||||
const { _id: domainId } = statusPage.domains[0];
|
||||
request
|
||||
.delete(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.delete(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
if (err) throw err;
|
||||
@@ -862,7 +862,7 @@ describe('Status API', function() {
|
||||
// create random status page id
|
||||
const statusPageId = '5ea70eb4be9f4b177a1719ad';
|
||||
request
|
||||
.delete(`/statusPage/${projectId}/${statusPageId}/${domainId}`)
|
||||
.delete(`/status-page/${projectId}/${statusPageId}/${domainId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end((err, res) => {
|
||||
if (err) throw err;
|
||||
@@ -948,7 +948,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
anotherUserToken = res.body.tokens.jwtAccessToken;
|
||||
const authorization = `Basic ${anotherUserToken}`;
|
||||
request
|
||||
.post(`/statusPage/${projectId}`)
|
||||
.post(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
links: [],
|
||||
@@ -985,7 +985,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should not get private status page for authorized user that is not in project', function(done) {
|
||||
const authorization = `Basic ${newUserToken}`;
|
||||
request
|
||||
.get(`/statusPage/${privateStatusPageId}`)
|
||||
.get(`/status-page/${privateStatusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -997,7 +997,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should not create a statusPage for user that is not `admin` in sub-project.', function(done) {
|
||||
const authorization = `Basic ${newUserToken}`;
|
||||
request
|
||||
.post(`/statusPage/${subProjectId}`)
|
||||
.post(`/status-page/${subProjectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
links: [],
|
||||
@@ -1032,7 +1032,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should create a statusPage in parent project by valid admin.', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.post(`/statusPage/${projectId}`)
|
||||
.post(`/status-page/${projectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
links: [],
|
||||
@@ -1068,7 +1068,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should create a statusPage in sub-project by valid admin.', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.post(`/statusPage/${subProjectId}`)
|
||||
.post(`/status-page/${subProjectId}`)
|
||||
.set('Authorization', authorization)
|
||||
.send({
|
||||
links: [],
|
||||
@@ -1103,7 +1103,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it("should get only sub-project's statuspages for valid sub-project user", function(done) {
|
||||
const authorization = `Basic ${newUserToken}`;
|
||||
request
|
||||
.get(`/statusPage/${subProjectId}/statuspage`)
|
||||
.get(`/status-page/${subProjectId}/statuspage`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -1119,7 +1119,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should get both project and sub-project statuspage for valid parent project user.', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.get(`/statusPage/${projectId}/statuspages`)
|
||||
.get(`/status-page/${projectId}/statuspages`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -1145,7 +1145,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
})
|
||||
.end(function() {
|
||||
request
|
||||
.get(`/statusPage/${subProjectStatusPageId}`)
|
||||
.get(`/status-page/${subProjectStatusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -1160,7 +1160,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should not delete a status page for user that is not `admin` in sub-project.', function(done) {
|
||||
const authorization = `Basic ${newUserToken}`;
|
||||
request
|
||||
.delete(`/statusPage/${subProjectId}/${subProjectStatusPageId}`)
|
||||
.delete(`/status-page/${subProjectId}/${subProjectStatusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -1175,7 +1175,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should delete sub-project status page', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.delete(`/statusPage/${subProjectId}/${subProjectStatusPageId}`)
|
||||
.delete(`/status-page/${subProjectId}/${subProjectStatusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
@@ -1187,7 +1187,7 @@ describe('StatusPage API with Sub-Projects', function() {
|
||||
it('should delete parent project status page', function(done) {
|
||||
const authorization = `Basic ${token}`;
|
||||
request
|
||||
.delete(`/statusPage/${projectId}/${statusPageId}`)
|
||||
.delete(`/status-page/${projectId}/${statusPageId}`)
|
||||
.set('Authorization', authorization)
|
||||
.end(function(err, res) {
|
||||
if (err) throw err;
|
||||
|
||||
@@ -97,7 +97,7 @@ describe('Subscriber API', function() {
|
||||
).to.be.equal(monitor.name);
|
||||
request
|
||||
.post(
|
||||
`/statusPage/${projectId}`
|
||||
`/status-page/${projectId}`
|
||||
)
|
||||
.set(
|
||||
'Authorization',
|
||||
|
||||
@@ -85,7 +85,7 @@ export function createDomain({
|
||||
|
||||
try {
|
||||
const response = await putApi(
|
||||
`statusPage/${projectId}/${statusPageId}/domain`,
|
||||
`status-page/${projectId}/${statusPageId}/domain`,
|
||||
{ domain, cert, privateKey, enableHttps, autoProvisioning }
|
||||
);
|
||||
dispatch(createDomainSuccess(response.data));
|
||||
@@ -128,7 +128,7 @@ export function deleteDomain({ projectId, statusPageId, domainId }) {
|
||||
dispatch(deleteDomainRequest());
|
||||
try {
|
||||
const response = await deleteApi(
|
||||
`statusPage/${projectId}/${statusPageId}/${domainId}`
|
||||
`status-page/${projectId}/${statusPageId}/${domainId}`
|
||||
);
|
||||
dispatch(deleteDomainSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -179,7 +179,7 @@ export function updateDomain({
|
||||
dispatch(updateDomainRequest());
|
||||
try {
|
||||
const response = await putApi(
|
||||
`statusPage/${projectId}/${statusPageId}/${domainId}`,
|
||||
`status-page/${projectId}/${statusPageId}/${domainId}`,
|
||||
{ domain, cert, privateKey, enableHttps, autoProvisioning }
|
||||
);
|
||||
dispatch(updateDomainSuccess(response.data));
|
||||
|
||||
@@ -28,7 +28,7 @@ export function createStatusPageError(error) {
|
||||
// Calls the API to create statuspage.
|
||||
export function createStatusPage(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(`statusPage/${projectId}`, data);
|
||||
const promise = postApi(`status-page/${projectId}`, data);
|
||||
dispatch(createStatusPageRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -100,7 +100,7 @@ export function uploadCertFile(projectId, file) {
|
||||
if (file) {
|
||||
data.append('cert', file);
|
||||
|
||||
const promise = postApi(`statusPage/${projectId}/certFile`, data);
|
||||
const promise = postApi(`status-page/${projectId}/certFile`, data);
|
||||
dispatch(uploadCertFileRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -162,7 +162,7 @@ export function uploadPrivateKey(projectId, file) {
|
||||
data.append('privateKey', file);
|
||||
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/privateKeyFile`,
|
||||
`status-page/${projectId}/privateKeyFile`,
|
||||
data
|
||||
);
|
||||
dispatch(uploadPrivateKeyRequest());
|
||||
@@ -217,7 +217,7 @@ export function updateStatusPageSettingError(error) {
|
||||
// Calls the API to update setting.
|
||||
export function updateStatusPageSetting(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, data);
|
||||
const promise = putApi(`status-page/${projectId}`, data);
|
||||
dispatch(updateStatusPageSettingRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -269,7 +269,7 @@ export function updateStatusPageMonitorsError(error) {
|
||||
// Calls the API to update monitors.
|
||||
export function updateStatusPageMonitors(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateStatusPageMonitorsRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -320,7 +320,7 @@ export function updatePrivateStatusPageError(error) {
|
||||
// Calls the API to update private statuspages.
|
||||
export function updatePrivateStatusPage(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updatePrivateStatusPageRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -370,7 +370,7 @@ export function updateSubscriberOptionError(error) {
|
||||
// update status page multi language
|
||||
export function updateStatusPageLanguage(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateStatusPageLanguageRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -420,7 +420,7 @@ export function updateStatusPageLanguageError(error) {
|
||||
// Calls the API to update private statuspages.
|
||||
export function updateSubscriberOption(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateSubscriberOptionRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -541,7 +541,7 @@ export function updateStatusPageBranding(projectId, values) {
|
||||
|
||||
if (values._id) data.append('_id', values._id);
|
||||
|
||||
const promise = putApi(`statusPage/${projectId}`, data);
|
||||
const promise = putApi(`status-page/${projectId}`, data);
|
||||
dispatch(updateStatusPageBrandingRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -570,7 +570,7 @@ export function updateStatusPageBranding(projectId, values) {
|
||||
// Calls the API to update the theme
|
||||
export function updateTheme(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}/theme`, data);
|
||||
const promise = putApi(`status-page/${projectId}/theme`, data);
|
||||
dispatch(updateStatusPageThemeRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -600,7 +600,7 @@ export function updateTheme(projectId, data) {
|
||||
// Calls the API to update status page name.
|
||||
export function updateStatusPageName(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateStatusPageNameRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -651,7 +651,7 @@ export function updateStatusPageLinksError(error) {
|
||||
// Calls the API to update links.
|
||||
export function updateStatusPageLinks(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateStatusPageLinksRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -702,7 +702,7 @@ export function updateStatusPageCustomHTMLError(error) {
|
||||
// Calls the API to update links.
|
||||
export function updateStatusPageCustomHTML(projectId, values) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, values);
|
||||
const promise = putApi(`status-page/${projectId}`, values);
|
||||
dispatch(updateStatusPageCustomHTMLRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -760,7 +760,7 @@ export function fetchProjectStatusPageError(error) {
|
||||
export function fetchProjectStatusPage(projectId, refresh, skip, limit) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/statuspage?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/statuspage?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
if (!refresh) dispatch(fetchProjectStatusPageRequest());
|
||||
|
||||
@@ -819,7 +819,7 @@ export function fetchSubProjectStatusPagesError(error) {
|
||||
// Gets status pages by subProjectId.
|
||||
export function fetchSubProjectStatusPages(projectId, refresh) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(`statusPage/${projectId}/statuspages`);
|
||||
const promise = getApi(`status-page/${projectId}/statuspages`);
|
||||
if (!refresh) dispatch(fetchSubProjectStatusPagesRequest());
|
||||
|
||||
promise.then(
|
||||
@@ -926,7 +926,7 @@ export function resetStatusBubbleIdError(error) {
|
||||
export function resetStatusBubbleId(projectId, statusPageId) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(
|
||||
`statusPage/${projectId}/${statusPageId}/resetBubbleId`,
|
||||
`status-page/${projectId}/${statusPageId}/resetBubbleId`,
|
||||
{}
|
||||
);
|
||||
dispatch(resetStatusBubbleIdRequest());
|
||||
@@ -984,7 +984,7 @@ export function deleteStatusPageError(error) {
|
||||
export function deleteStatusPage(projectId, statusPageSlug) {
|
||||
return function(dispatch) {
|
||||
const promise = deleteApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}`,
|
||||
`status-page/${projectId}/${statusPageSlug}`,
|
||||
null
|
||||
);
|
||||
dispatch(deleteStatusPageRequest());
|
||||
@@ -1034,7 +1034,7 @@ export function duplicateStatusPageError(error) {
|
||||
|
||||
export function readStatusPage(statusPageSlug, data) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(`statusPage/${statusPageSlug}`, data);
|
||||
const promise = getApi(`status-page/${statusPageSlug}`, data);
|
||||
dispatch(duplicateStatusPageRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1070,8 +1070,8 @@ export function createDuplicateStatusPage(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const url = subProjectId
|
||||
? `statusPage/${projectId}/${statusPageSlug}/duplicateStatusPage?subProjectId=${subProjectId}`
|
||||
: `statusPage/${projectId}/${statusPageSlug}/duplicateStatusPage`;
|
||||
? `status-page/${projectId}/${statusPageSlug}/duplicateStatusPage?subProjectId=${subProjectId}`
|
||||
: `status-page/${projectId}/${statusPageSlug}/duplicateStatusPage`;
|
||||
const promise = postApi(url, data);
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1097,7 +1097,7 @@ export function createDuplicateStatusPage(
|
||||
|
||||
export function fetchStatusPage(statusPageSlug) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(`statusPage/${statusPageSlug}`);
|
||||
const promise = getApi(`status-page/${statusPageSlug}`);
|
||||
promise.then(
|
||||
function(response) {
|
||||
const statusPageData = response.data;
|
||||
@@ -1155,7 +1155,7 @@ export function updateStatusPageEmbeddedCssError(error) {
|
||||
// Calls the API to update setting.
|
||||
export function updateStatusPageEmbeddedCss(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, data);
|
||||
const promise = putApi(`status-page/${projectId}`, data);
|
||||
dispatch(updateStatusPageEmbeddedCssRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1208,7 +1208,7 @@ export function resetBrandingColorsError(error) {
|
||||
export function resetBrandingColors(projectId, statusPageId) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(
|
||||
`statusPage/${projectId}/${statusPageId}/resetColors`
|
||||
`status-page/${projectId}/${statusPageId}/resetColors`
|
||||
);
|
||||
dispatch(resetBrandingColorsRequest());
|
||||
promise.then(
|
||||
@@ -1260,7 +1260,7 @@ export function resetStatusPageEmbeddedCssError(error) {
|
||||
// Calls the API to update setting.
|
||||
export function resetStatusPageEmbeddedCss(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, data);
|
||||
const promise = putApi(`status-page/${projectId}`, data);
|
||||
dispatch(resetStatusPageEmbeddedCssRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1309,7 +1309,7 @@ export function updateStatusPageLayoutError(error) {
|
||||
|
||||
export function updateStatusPageLayout(projectId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(`statusPage/${projectId}`, data);
|
||||
const promise = putApi(`status-page/${projectId}`, data);
|
||||
dispatch(updateStatusPageLayoutRequest());
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1365,7 +1365,7 @@ export function fetchStatusPageSubscribers(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/monitor/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/monitor/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
dispatch(fetchSubscriberRequest());
|
||||
promise.then(
|
||||
@@ -1413,7 +1413,7 @@ export function createExternalStatusPageFailure(error) {
|
||||
export function createExternalStatusPage(projectId, statusPageId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/createExternalStatusPage/${statusPageId}`,
|
||||
`status-page/${projectId}/createExternalstatus-page/${statusPageId}`,
|
||||
data
|
||||
);
|
||||
dispatch(createExternalStatusPageRequest());
|
||||
@@ -1469,7 +1469,7 @@ export function updateExternalStatusPage(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/updateExternalStatusPage/${externalStatusPageId}`,
|
||||
`status-page/${projectId}/updateExternalstatus-page/${externalStatusPageId}`,
|
||||
data
|
||||
);
|
||||
dispatch(updateExternalStatusPageRequest());
|
||||
@@ -1521,7 +1521,7 @@ export function fetchExternalStatusPagesFailure(error) {
|
||||
export function fetchExternalStatusPages(projectId, statusPageId) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/fetchExternalStatusPages/${statusPageId}`
|
||||
`status-page/${projectId}/fetchExternalStatusPages/${statusPageId}`
|
||||
);
|
||||
dispatch(fetchExternalStatusPagesRequest());
|
||||
promise.then(
|
||||
@@ -1572,7 +1572,7 @@ export function deleteExternalStatusPageFailure(error) {
|
||||
export function deleteExternalStatusPage(projectId, externalStatusPageId) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/deleteExternalStatusPage/${externalStatusPageId}`
|
||||
`status-page/${projectId}/deleteExternalstatus-page/${externalStatusPageId}`
|
||||
);
|
||||
dispatch(deleteExternalStatusPageRequest());
|
||||
promise.then(
|
||||
@@ -1623,7 +1623,7 @@ export function createAnnouncementFailure(error) {
|
||||
export function createAnnouncement(projectId, statusPageId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageId}`,
|
||||
`status-page/${projectId}/announcement/${statusPageId}`,
|
||||
data
|
||||
);
|
||||
dispatch(createAnnouncementRequest());
|
||||
@@ -1660,7 +1660,7 @@ export function updateAnnouncement(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = putApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageId}/${announcementId}`,
|
||||
`status-page/${projectId}/announcement/${statusPageId}/${announcementId}`,
|
||||
data
|
||||
);
|
||||
dispatch(createAnnouncementRequest());
|
||||
@@ -1712,7 +1712,7 @@ export function fetchAnnouncementFailure(error) {
|
||||
export function fetchAnnouncements(projectId, statusPageId, skip = 0, limit) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/announcement/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
dispatch(fetchAnnouncementRequest());
|
||||
promise.then(
|
||||
@@ -1765,7 +1765,7 @@ export function fetchAnnouncementLogs(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcementLogs/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/announcementLogs/${statusPageId}?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
dispatch(fetchAnnouncementLogsRequest());
|
||||
promise.then(
|
||||
@@ -1811,7 +1811,7 @@ export function fetchSingleAnnouncement(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageSlug}/single/${announcementSlug}`
|
||||
`status-page/${projectId}/announcement/${statusPageSlug}/single/${announcementSlug}`
|
||||
);
|
||||
promise.then(
|
||||
function(response) {
|
||||
@@ -1884,7 +1884,7 @@ export function deleteAnnouncementFailure(error) {
|
||||
export function deleteAnnouncement(projectId, announcementId) {
|
||||
return function(dispatch) {
|
||||
const promise = deleteApi(
|
||||
`statusPage/${projectId}/announcement/${announcementId}/delete`
|
||||
`status-page/${projectId}/announcement/${announcementId}/delete`
|
||||
);
|
||||
dispatch(deleteAnnouncementRequest());
|
||||
promise.then(
|
||||
@@ -1912,7 +1912,7 @@ export function deleteAnnouncement(projectId, announcementId) {
|
||||
export function deleteAnnouncementLog(projectId, announcementLogId) {
|
||||
return function(dispatch) {
|
||||
const promise = deleteApi(
|
||||
`statusPage/${projectId}/announcementLog/${announcementLogId}/delete`
|
||||
`status-page/${projectId}/announcementLog/${announcementLogId}/delete`
|
||||
);
|
||||
dispatch(deleteAnnouncementRequest());
|
||||
promise.then(
|
||||
|
||||
@@ -123,7 +123,7 @@ export class EmbeddedBubble extends Component {
|
||||
});
|
||||
};
|
||||
changecss = (event, css) => {
|
||||
const url = `${API_URL}/statusPage/statusBubble?statusPageId=${this.props.statusPageId}&statusBubbleId=${this.props.statusBubbleId}`;
|
||||
const url = `${API_URL}/status-page/statusBubble?statusPageId=${this.props.statusPageId}&statusBubbleId=${this.props.statusBubbleId}`;
|
||||
const value = createScript(url, css);
|
||||
this.props.change('embeddedcode', value);
|
||||
};
|
||||
@@ -580,7 +580,7 @@ const mapStateToProps = state => {
|
||||
colors,
|
||||
embeddedCss,
|
||||
} = state.statusPage.status;
|
||||
const url = `${API_URL}/statusPage/statusBubble?statusPageId=${_id}&statusBubbleId=${statusBubbleId}`;
|
||||
const url = `${API_URL}/status-page/statusBubble?statusPageId=${_id}&statusBubbleId=${statusBubbleId}`;
|
||||
const customCss =
|
||||
embeddedCss && embeddedCss.length ? embeddedCss : css(colors);
|
||||
const script = createScript(url, customCss);
|
||||
|
||||
@@ -3,18 +3,18 @@ import { bindActionCreators } from 'redux';
|
||||
import { connect } from 'react-redux';
|
||||
import Fade from 'react-reveal/Fade';
|
||||
import ShouldRender from '../components/basic/ShouldRender';
|
||||
import Setting from '../components/statusPage/Setting';
|
||||
import Basic from '../components/statusPage/Basic';
|
||||
import Header from '../components/statusPage/Header';
|
||||
import Monitors from '../components/statusPage/Monitors';
|
||||
import Branding from '../components/statusPage/Branding';
|
||||
import StatusPageLayout from '../components/statusPage/StatusPageLayout';
|
||||
import Links from '../components/statusPage/Links';
|
||||
import DeleteBox from '../components/statusPage/DeleteBox';
|
||||
import DuplicateStatusBox from '../components/statusPage/DuplicateStatusPage';
|
||||
import ExternalStatusPages from '../components/statusPage/ExternalStatusPages';
|
||||
import PrivateStatusPage from '../components/statusPage/PrivateStatusPage';
|
||||
import StatusPageLanguage from '../components/statusPage/StatusPageLanguage';
|
||||
import Setting from '../components/status-page/Setting';
|
||||
import Basic from '../components/status-page/Basic';
|
||||
import Header from '../components/status-page/Header';
|
||||
import Monitors from '../components/status-page/Monitors';
|
||||
import Branding from '../components/status-page/Branding';
|
||||
import StatusPageLayout from '../components/status-page/StatusPageLayout';
|
||||
import Links from '../components/status-page/Links';
|
||||
import DeleteBox from '../components/status-page/DeleteBox';
|
||||
import DuplicateStatusBox from '../components/status-page/DuplicateStatusPage';
|
||||
import ExternalStatusPages from '../components/status-page/ExternalStatusPages';
|
||||
import PrivateStatusPage from '../components/status-page/PrivateStatusPage';
|
||||
import StatusPageLanguage from '../components/status-page/StatusPageLanguage';
|
||||
import RenderIfSubProjectAdmin from '../components/basic/RenderIfSubProjectAdmin';
|
||||
import { FormLoader, LoadingState } from '../components/basic/Loader';
|
||||
import PropTypes from 'prop-types';
|
||||
@@ -27,18 +27,18 @@ import {
|
||||
fetchProjectStatusPage,
|
||||
updateStatusPageMonitors,
|
||||
} from '../actions/statusPage';
|
||||
import CustomStyles from '../components/statusPage/CustomStyles';
|
||||
import EmbeddedBubble from '../components/statusPage/EmbeddedBubble';
|
||||
import CustomStyles from '../components/status-page/CustomStyles';
|
||||
import EmbeddedBubble from '../components/status-page/EmbeddedBubble';
|
||||
import BreadCrumbItem from '../components/breadCrumb/BreadCrumbItem';
|
||||
import getParentRoute from '../utils/getParentRoute';
|
||||
import { Tab, Tabs, TabList, TabPanel, resetIdCounter } from 'react-tabs';
|
||||
import Themes from '../components/statusPage/Themes';
|
||||
import StatusPageSubscriber from '../components/statusPage/StatusPageSubscriber';
|
||||
import Announcements from '../components/statusPage/Announcements';
|
||||
import StatusPageCategory from '../components/statusPage/StatusPageCategory';
|
||||
import Themes from '../components/status-page/Themes';
|
||||
import StatusPageSubscriber from '../components/status-page/StatusPageSubscriber';
|
||||
import Announcements from '../components/status-page/Announcements';
|
||||
import StatusPageCategory from '../components/status-page/StatusPageCategory';
|
||||
import { fetchAllStatusPageCategories } from '../actions/statusPageCategory';
|
||||
import MonitorsWithCategory from '../components/statusPage/MonitorsWithCategory';
|
||||
import EmptyCategory from '../components/statusPage/EmptyCategory';
|
||||
import MonitorsWithCategory from '../components/status-page/MonitorsWithCategory';
|
||||
import EmptyCategory from '../components/status-page/EmptyCategory';
|
||||
import { fetchComponents } from '../actions/component';
|
||||
import { fetchMonitors } from '../actions/monitor';
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ import React, { Component } from 'react';
|
||||
import { bindActionCreators } from 'redux';
|
||||
import { connect } from 'react-redux';
|
||||
import Fade from 'react-reveal/Fade';
|
||||
import StatusPagesTable from '../components/statusPage/StatusPagesTable';
|
||||
import StatusPagesTable from '../components/status-page/StatusPagesTable';
|
||||
import PropTypes from 'prop-types';
|
||||
import ShouldRender from '../components/basic/ShouldRender';
|
||||
import TutorialBox from '../components/tutorial/TutorialBox';
|
||||
|
||||
@@ -97,7 +97,7 @@ server {
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_pass http://statuspage/;
|
||||
proxy_pass http://status-page/;
|
||||
}
|
||||
location /api {
|
||||
rewrite ^/api/(.*) /$1 break;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -41,7 +41,7 @@ const client = getMongoClient();
|
||||
})();
|
||||
|
||||
if (!NODE_ENV || NODE_ENV === 'development') {
|
||||
// Load env vars from /statuspage/.env
|
||||
// Load env vars from /status-page/.env
|
||||
require('dotenv').config();
|
||||
}
|
||||
|
||||
|
||||
@@ -11,10 +11,10 @@ export function getProbes(projectId, skip, limit) {
|
||||
let promise = null;
|
||||
if (skip >= 0 && limit >= 0) {
|
||||
promise = getApi(
|
||||
`statusPage/${projectId}/probes?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/probes?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
} else {
|
||||
promise = getApi(`statusPage/${projectId}/probes`);
|
||||
promise = getApi(`status-page/${projectId}/probes`);
|
||||
}
|
||||
dispatch(probeRequest(promise));
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ export const statusPageFailure = error => {
|
||||
// Calls the API to get status
|
||||
export const getStatusPage = (statusPageSlug, url) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(`statusPage/${statusPageSlug}?url=${url}`);
|
||||
const promise = getApi(`status-page/${statusPageSlug}?url=${url}`);
|
||||
|
||||
dispatch(statusPageRequest());
|
||||
|
||||
@@ -70,61 +70,61 @@ export const getAllStatusPageResource = (statusPageSlug, url, range) => {
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/ongoing-events?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/ongoing-events?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/future-events?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/future-events?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/past-events?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/past-events?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/probes?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/probes?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/monitor-logs?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/monitor-logs?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/announcements?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/announcements?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/announcement-logs?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/announcement-logs?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/monitor-timelines?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/monitor-timelines?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/statuspage-notes?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/statuspage-notes?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
promises.push(
|
||||
getApi(
|
||||
`statusPage/resources/${statusPageSlug}/monitor-statuses?url=${url}&range=${range}`
|
||||
`status-page/resources/${statusPageSlug}/monitor-statuses?url=${url}&range=${range}`
|
||||
)
|
||||
);
|
||||
|
||||
@@ -268,7 +268,7 @@ export const getStatusPageNote = (
|
||||
) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/notes?skip=${skip}&limit=${limit}&days=${days}&newTheme=${newTheme}`
|
||||
`status-page/${projectId}/${statusPageSlug}/notes?skip=${skip}&limit=${limit}&days=${days}&newTheme=${newTheme}`
|
||||
);
|
||||
|
||||
dispatch(statusPageNoteRequest());
|
||||
@@ -307,7 +307,7 @@ export const getStatusPageIndividualNote = (
|
||||
) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${monitorId}/individualnotes?date=${date}&need=${need}&theme=${theme}`
|
||||
`status-page/${projectId}/${monitorId}/individualnotes?date=${date}&need=${need}&theme=${theme}`
|
||||
);
|
||||
|
||||
dispatch(statusPageNoteRequest());
|
||||
@@ -380,7 +380,7 @@ export const getScheduledEvent = (
|
||||
) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/events?skip=${skip}&theme=${theme}&days=${days}`
|
||||
`status-page/${projectId}/${statusPageSlug}/events?skip=${skip}&theme=${theme}&days=${days}`
|
||||
);
|
||||
|
||||
dispatch(scheduledEventRequest());
|
||||
@@ -443,7 +443,7 @@ export const getOngoingScheduledEvent = (
|
||||
) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/events?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
`status-page/${projectId}/${statusPageSlug}/events?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
);
|
||||
|
||||
dispatch(ongoingEventRequest());
|
||||
@@ -488,7 +488,7 @@ export const individualEventsFailure = error => ({
|
||||
export const getIndividualEvent = (projectId, monitorId, date, name, theme) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${monitorId}/individualevents?date=${date}&theme=${theme}`
|
||||
`status-page/${projectId}/${monitorId}/individualevents?date=${date}&theme=${theme}`
|
||||
);
|
||||
|
||||
dispatch(individualEventsRequest());
|
||||
@@ -545,7 +545,7 @@ export const fetchFutureEvents = (
|
||||
try {
|
||||
dispatch(futureEventsRequest());
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/futureEvents?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
`status-page/${projectId}/${statusPageSlug}/futureEvents?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
);
|
||||
dispatch(futureEventsSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -585,7 +585,7 @@ export const fetchPastEvents = (
|
||||
try {
|
||||
dispatch(pastEventsRequest());
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/pastEvents?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
`status-page/${projectId}/${statusPageSlug}/pastEvents?skip=${skip}&theme=${theme}&limit=${limit}`
|
||||
);
|
||||
dispatch(pastEventsSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -640,7 +640,7 @@ export const moreNoteFailure = error => {
|
||||
export const getMoreNote = (projectId, statusPageSlug, skip) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/notes?skip=${skip}`
|
||||
`status-page/${projectId}/${statusPageSlug}/notes?skip=${skip}`
|
||||
);
|
||||
|
||||
dispatch(moreNoteRequest());
|
||||
@@ -689,7 +689,7 @@ export const moreEventFailure = error => {
|
||||
export const getMoreEvent = (projectId, statusPageSlug, skip) => {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/events?skip=${skip}`
|
||||
`status-page/${projectId}/${statusPageSlug}/events?skip=${skip}`
|
||||
);
|
||||
|
||||
dispatch(moreEventRequest());
|
||||
@@ -738,7 +738,7 @@ export const fetchMoreFutureEvents = (
|
||||
try {
|
||||
dispatch(moreFutureEventsRequest());
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/futureEvents?skip=${skip}&limit=${limit}`
|
||||
`status-page/${projectId}/${statusPageSlug}/futureEvents?skip=${skip}&limit=${limit}`
|
||||
);
|
||||
dispatch(moreFutureEventsSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -776,7 +776,7 @@ export const fetchMorePastEvents = (
|
||||
try {
|
||||
dispatch(morePastEventsRequest());
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/pastEvents?skip=${skip}`
|
||||
`status-page/${projectId}/${statusPageSlug}/pastEvents?skip=${skip}`
|
||||
);
|
||||
dispatch(morePastEventsSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -805,7 +805,7 @@ export function selectedProbe(val) {
|
||||
export function fetchMonitorStatuses(projectId, monitorId, startDate, endDate) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/${monitorId}/monitorStatuses`,
|
||||
`status-page/${projectId}/${monitorId}/monitorStatuses`,
|
||||
{ startDate, endDate }
|
||||
);
|
||||
dispatch(fetchMonitorStatusesRequest(monitorId));
|
||||
@@ -865,7 +865,7 @@ export function fetchMonitorStatusesFailure(error) {
|
||||
export function fetchMonitorLogs(projectId, monitorId, data) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(
|
||||
`statusPage/${projectId}/${monitorId}/monitorLogs`,
|
||||
`status-page/${projectId}/${monitorId}/monitorLogs`,
|
||||
data
|
||||
);
|
||||
dispatch(fetchMonitorLogsRequest(monitorId));
|
||||
@@ -946,7 +946,7 @@ export function fetchEvent(projectId, scheduledEventId) {
|
||||
|
||||
try {
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/scheduledEvent/${scheduledEventId}`
|
||||
`status-page/${projectId}/scheduledEvent/${scheduledEventId}`
|
||||
);
|
||||
dispatch(fetchEventSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -990,7 +990,7 @@ export function fetchEventNote(projectId, scheduledEventSlug, type) {
|
||||
|
||||
try {
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/notes/${scheduledEventSlug}?type=${type}`
|
||||
`status-page/${projectId}/notes/${scheduledEventSlug}?type=${type}`
|
||||
);
|
||||
dispatch(fetchEventNoteSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1033,7 +1033,7 @@ export function moreEventNote(projectId, scheduledEventId, type, skip) {
|
||||
dispatch(moreEventNoteRequest());
|
||||
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/notes/${scheduledEventId}?type=${type}&skip=${skip}`
|
||||
`status-page/${projectId}/notes/${scheduledEventId}?type=${type}&skip=${skip}`
|
||||
);
|
||||
dispatch(moreEventNoteSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1076,7 +1076,7 @@ export function fetchIncident(projectId, incidentSlug) {
|
||||
try {
|
||||
dispatch(fetchIncidentRequest());
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/incident/${incidentSlug}`
|
||||
`status-page/${projectId}/incident/${incidentSlug}`
|
||||
);
|
||||
|
||||
dispatch(fetchIncidentSuccess(response.data));
|
||||
@@ -1120,7 +1120,7 @@ export function fetchIncidentNotes(projectId, incidentId, postOnStatusPage) {
|
||||
dispatch(fetchIncidentNotesRequest());
|
||||
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${incidentId}/incidentNotes?postOnStatusPage=${postOnStatusPage}`
|
||||
`status-page/${projectId}/${incidentId}/incidentNotes?postOnStatusPage=${postOnStatusPage}`
|
||||
);
|
||||
dispatch(fetchIncidentNotesSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1168,7 +1168,7 @@ export function moreIncidentNotes(
|
||||
dispatch(moreIncidentNotesRequest());
|
||||
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${incidentSlug}/incidentNotes?postOnStatusPage=${postOnStatusPage}&skip=${skip}`
|
||||
`status-page/${projectId}/${incidentSlug}/incidentNotes?postOnStatusPage=${postOnStatusPage}&skip=${skip}`
|
||||
);
|
||||
dispatch(moreIncidentNotesSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1211,7 +1211,7 @@ export function fetchLastIncidentTimeline(projectId, incidentSlug) {
|
||||
dispatch(fetchLastIncidentTimelineRequest());
|
||||
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/timeline/${incidentSlug}`
|
||||
`status-page/${projectId}/timeline/${incidentSlug}`
|
||||
);
|
||||
dispatch(fetchLastIncidentTimelineSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1254,7 +1254,7 @@ export function fetchLastIncidentTimelines(projectId, statusPageSlug) {
|
||||
dispatch(fetchLastIncidentTimelinesRequest());
|
||||
|
||||
const response = await getApi(
|
||||
`statusPage/${projectId}/${statusPageSlug}/timelines`
|
||||
`status-page/${projectId}/${statusPageSlug}/timelines`
|
||||
);
|
||||
dispatch(fetchLastIncidentTimelinesSuccess(response.data));
|
||||
} catch (error) {
|
||||
@@ -1302,7 +1302,7 @@ export function getAnnouncementsFailure(data) {
|
||||
export function getAnnouncements(projectId, statusPageId, skip = 0, limit) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageId}?skip=${skip}&limit=${limit}&show=true`
|
||||
`status-page/${projectId}/announcement/${statusPageId}?skip=${skip}&limit=${limit}&show=true`
|
||||
);
|
||||
dispatch(getAnnouncementsRequest());
|
||||
promise.then(
|
||||
@@ -1352,7 +1352,7 @@ export function getSingleAnnouncement(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcement/${statusPageSlug}/single/${announcementSlug}`
|
||||
`status-page/${projectId}/announcement/${statusPageSlug}/single/${announcementSlug}`
|
||||
);
|
||||
dispatch(getSingleAnnouncementRequest());
|
||||
promise.then(
|
||||
@@ -1403,7 +1403,7 @@ export function fetchAnnouncementLogs(
|
||||
) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/announcementLogs/${statusPageId}?skip=${skip}&limit=${limit}&theme=${true}`
|
||||
`status-page/${projectId}/announcementLogs/${statusPageId}?skip=${skip}&limit=${limit}&theme=${true}`
|
||||
);
|
||||
dispatch(fetchAnnouncementLogsRequest());
|
||||
promise.then(
|
||||
@@ -1502,7 +1502,7 @@ export function fetchTweetsFailure(error) {
|
||||
|
||||
export function fetchTweets(handle, projectId) {
|
||||
return function(dispatch) {
|
||||
const promise = postApi(`statusPage/${projectId}/tweets`, {
|
||||
const promise = postApi(`status-page/${projectId}/tweets`, {
|
||||
handle,
|
||||
});
|
||||
|
||||
@@ -1552,7 +1552,7 @@ export function fetchExternalStatusPagesFailure(error) {
|
||||
export function fetchExternalStatusPages(projectId, statusPageId) {
|
||||
return function(dispatch) {
|
||||
const promise = getApi(
|
||||
`statusPage/${projectId}/fetchExternalStatusPages/${statusPageId}`
|
||||
`status-page/${projectId}/fetchExternalStatusPages/${statusPageId}`
|
||||
);
|
||||
|
||||
dispatch(fetchExternalStatusPagesRequest());
|
||||
|
||||
@@ -220,7 +220,7 @@ class SubscribeBox extends Component {
|
||||
<div className="directions">
|
||||
Get the{' '}
|
||||
<a
|
||||
href={`${API_URL}/statusPage/${statusPage._id}/rss`}
|
||||
href={`${API_URL}/status-page/${statusPage._id}/rss`}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
style={{
|
||||
|
||||
Reference in New Issue
Block a user