- Users
- Activities
- Institutions
- Internships
- Residences
- Studies
- Events
- Event Modules
- EventsActivities
- Publications
- Exams
- ExamResponses
- Recursos
- Payments
Send all queries as MONGODB syntax in String format(stringify)
POST /auth/signup
POST /auth/login
GET /auth/self
POST /auth/change
{email, oldPassword, newPassword}
POST /auth/forgot
{email, password}
POST /users/:userId/follow
GET /users/:userId
PATCH /users/:userId
// Send the user image file in the photo field
DELETE /users/:userId
GET /users?query={"userStatus":"Aprobado", "filter":"value"}&limit=20&skip=0
residentLetter
{
"email":"example@example.com",
"basicData":{
"name" :"oswaldinho",
"dadSurname":"Martinez",
"momSurname":"Anaya",
"birthDate":"31/08/1996",
"placeOfBirth":{
"addressName":"Pachuca",
"street":"",
"outdoorNumber":"",
"interiorNumber":"",
"colony":"",
"zipCode":"",
"city":"Pachuca",
"state":"Hidalgo",
"coordinates":["123312","123123"]
},
"speciality" :=> ['Gastroenterología', 'Endoscopia', 'Motilidad', 'Medicina Interna', 'Cirujano', 'Otras']
"photoURL":"url de la foto",
"phone":"1234567890",
"civilStatus" :"one pf these=>['Soltero', 'Casado', 'Divorciado', 'Unión Libre', 'Viudo']",
"address":{
"addressName":"Pachuca",
"street":"",
"outdoorNumber":"",
"interiorNumber":"",
"colony":"",
"zipCode":"",
"city":"Pachuca",
"state":"Hidalgo",
"coordinates":["123312","123123"]
}
},
### cónyugue if casado o unión libre
"spouse":{
"name":"spouse name",
"dadSurname":"elapellido",
"momSurname":"el otro apellido",
"email":"email@conyugue.com",
"phone":"1234567890"
},
###* /Datos fiscales ***
"fiscalData":{
"rfc":"1234567RTY",
"phone":"1234567890" ,
"email":"email@email.com" ,
"address":{
"addressName":"Pachuca",
"street":"",
"outdoorNumber":"",
"interiorNumber":"",
"colony":"",
"zipCode":"",
"city":"Pachuca",
"state":"Hidalgo",
"coordinates":["123312","123123"]
}
},
###* Status Data ***
"registrationDate":"01/01/2010",
"userType": enum:['Member', 'Editor', 'Admin'],
"membershipStatus":"one of these=>: enum:['Free', 'Residente', 'Socio', 'Veterano'],
###* Aproval Data ***
"userStatus":"one of these=>['Registrado','Pendiente', 'Aprobado', 'No Aprobado']",
"revisionDate":"01/01/2010",
"reviwedBy":"the Object ID of the User",
"assistedEvents":[]
"assistedActivities":[]
###* "Miembros de la asociación mexicana de gastroenterología que recomiendan su ingreso" ***
"membersWhoRecommend":["the Object ID of the User", "the Object ID of the User"],
###* Condicional labora posee un consultorio ***
"consultories":["the Object ID of the Instituciones"],
###* educación ***
"studies":["the Object ID of the Studies"],
###* Internado de pregrado ***
"internships":["the Object ID of the Internships"],
###* Residencias y posgrados ***
"residencies":["the Object ID of the Residencies"],
###* Actividades docentes pasadas y presentes ***
"teachingActivities":["the Object ID of the Activities",],
###* Activityes hospitalarias pasadas y presentes ***
"hospitalActivities":["the Object ID of the Activities",],
###* Sociedades médicas a las que pertenece *** o usar un modelo por separado para Sociedades ***
"medicalSocieties":["the Object ID of the Activities",],
"createdAt":"01/01/2019",
"updatedAt":"01/01/2019"
}
GET /activities?query={"filter":"value"}&limit=20&skip=0
POST /activities
GET /activities/:activityId
PATCH /activities/:activityId
DELETE /activities/:activityId
##Model
{
user: ID of the User
type:one of these['Hospitalaria', 'Docente', 'Sociedad'],
institution:ID of an Institution
//If Docente
subject:'La materia'
//If Hospitalaria
charge :'El cargo'
startDate :'10/10/2010',
endDate :'10/10/2010'
}
GET /institutions?query={"filter":"value"}&limit=20&skip=0
POST /institutions
GET /institutions/:institushionId
PATCH /institutions/:institushionId
DELETE /institutions/:institushionId
##Model
{
name:'Institution Name'
president:''
type: => ['Hospital', 'Escuela', 'Consultorio', 'Sociedad']
location:{
"addressName":"Pachuca",
"street":"",
"outdoorNumber":"",
"interiorNumber":"",
"colony":"",
"zipCode":"",
"city":"Pachuca",
"state":"Hidalgo",
"coordinates":["123312","123123"]
},
phones:[124123412341234,123412341234],
email:'institutionmail@mail.com'
logoURL:'institution.jpg'
}
GET /internships?query={"filter":"value"}&limit=20&skip=0
POST /internships
GET /internships/:internshipId
PATCH /internships/:internshipId
DELETE /internships/:internshipId
##Model
{
user:User ID,
institution:Institution ID,
startDate:'10/10/10',
endDate :'10/10/10',
}
GET /residences?query={"filter":"value"}&limit=20&skip=0
POST /residences
GET /residences/:residenceId
PATCH /residences/:residenceId
DELETE /residences/:residenceId
##FIles certificado
##Model
{
user:User ID,
speciality:'especialidad',
institution:InstitutionID,
startDate:'10/10/10'
endDate :'10/10/10'
specialityLicence:'CEdula de especialidad'
specialityLicenceCopy :'file.jpg'
specialistLicence:'cedula de especialidad'
specialityDirectorsCertificates:'certificados del consejo de especialidad'
}
GET /studies?query={"filter":"value"}&limit=20&skip=0
POST /studies
GET /studies/:studyId
PATCH /studies/:studyId
DELETE /studies/:studyId
##Files
cedula titulo
##Model
{
user:User ID,
major:'Carrera'
institution:Institution ID,
startDate:'10/10/2010'
endDate:'10/10/2010'
//(Año de titulación)
receptionDate :'10/10/2015'
professionalLicence:'Cédula profesional'
}
GET /events?query={"filter":"value"}&limit=20&skip=0
POST /events
POST /events/:eventId/assist
DELETE /events/:eventId/unassist
POST /events/:eventId/speaker
it receives the object of the speaker in req.body and adds it to the speakers list in the event
if it has _id, it deletes it from the list
GET /events/:eventId
PATCH /events/:eventId
DELETE /events/:eventId
permisos
constancias
programas
logosInstitucionales
mainImages
thumbnailImages
iconImages
## Fields for speaker image
photo
{
### Datos Generales
"title":"El evento del año"
startTime:"10:10:10"
"startDate":"01/01/2019"
"endDate":"01/01/2019"
"description":['parrafo1', 'Párrafo2],
### Ubicación
location:{
"addressName":"Pachuca",
"street":"",
"outdoorNumber":"",
"interiorNumber":"",
"colony":"",
"zipCode":"",
"city":"Pachuca",
"state":"Hidalgo",
"coordinates":["123312","123123"]
},
###Programa
modules:[ids de los modulos],
###speakers
speakers:[{
title:'doctorazo'
fullName:'Oswaldso Martinez Anaya'
photoURL::'lalalalal.png'
city:'Pachuyork'
bio:'fit n geek'
}]
mainImagesURLS:[image urls],
thumbnailImagesURLS:[image urls],
iconImagesURLS:[image urls],
permisosURLS:[carta permiso url]
}
GET /eventModules?query={"filter":"value"}&limit=20&skip=0
POST /eventModules
GET /eventModules/:moduleId
PATCH /eventModules/:moduleId
DELETE /eventModules/:moduleId
{
event:id del evento ,
title:String,
description:String,
date:String,
/*just in case*/
activities:[{
type:Schema.Types.ObjectId,
ref:'EventActivity'
}]
}
GET /eventActivities?query={"filter":"value"}&limit=20&skip=0
POST /eventActivities
POST /eventActivities/:eventActivityId/assist
DELETE /eventActivities/:eventActivityId/unassist
GET /eventActivities/:eventActivityId
PATCH /eventActivities/:eventActivityId
DELETE /eventActivities/:eventActivityId
constancia
speakerPhoto
{
event:Event Id,
module:Module Id,
activityName:'Name of the activity
activityType:['Actividad', 'Conferencia', 'Taller', 'Otro'],
cost:1000,
limit:Number,
isOpen:Boolean (default is true)
description:String,
date:10/10/2019
address:String,
constanciaURL:constanciaURL,
speakers:[{}],
//asistentes
assistants:[ids de los asistentes]
}
GET /publications?query={"filter":"value"}&limit=20&skip=0
//to get the favorites of a user
/publications?query={"liked":{"$in":["userID"]}}
POST /publications
POST /publications/:publicationId/like
GET /publications/:publicationId
PATCH /publications/:publicationId
DELETE /publications/:publicationId
{
user:
urls:['url1', 'url2', 'url3'],
//para post mandar los archivos en formdata en el field images
//para get viene el array de los links de los archivos
imagesURLS:[],
//para post mandar los archivos en formdata en el field docs
//para get viene el array de los links de los archivos
docsURLS:[],
text:"texto del post",
liked:[urls de los usuarios que agregaron como fav el post]
}
GET /exams?query={"filter":"value"}&limit=20&skip=0
POST /exams
GET /exams/:examId
PATCH /exams/:examId
DELETE /exams/:examId
{
eventActivity: ID of the Activity EVent
title:El examen más perro del mundo,
date:10/10/10,
beginingTime:String,
endTime:String,
questions:[{
question:¿Porqué bla bla bla?,
answers:['la uno', 'la dos', 'la tres', 'la cuatro'],
correct:'la tres'
}]
}
GET /publications?query={"filter":"value"}&limit=20&skip=0
//to get the favorites of a user
/publications?query={"liked":{"$in":["userID"]}}
POST /publications
POST /publications/:publicationId/like
GET /publications/:publicationId
PATCH /publications/:publicationId
DELETE /publications/:publicationId
{
exam:ID of the Exam
user: ID of the user who ansers
answers:[
{
question:'kiubo??',
answer:'lol'
},
],
score:10
}
GET /recursos?query={"filter":"value"}&limit=20&skip=0
//to get the favorites of a user
/recursos?query={"liked":{"$in":["userID"]}}
//to search by title or authors or volume
/recursos?search=searchText
// use limit and skip to make pagination, total count is given in response
//
/recursos?limit=10&skip=10
POST /recursos
POST /recursos/:recursoId/like
GET /recursos/:recursoId
PATCH /recursos/:recursoId
DELETE /recursos/:recursoId
{
user:user Id,
url:String,
imagesURLS:['imagen.jpg],
docsURLS:['imagen.jpg'],
title:'titulin',
subtitle:'totulin',
footer:'footer',
liked:[userIDs],
tipo:enum:['Guías y consensos', 'Publicaciones'],
volume:String,
publishedAt:String,
authors:String
}
GET /payments?query={"filter":"value"}&limit=20&skip=0
//to get the favorites of a user
/payments?query={"liked":{"$in":["userID"]}}
POST /payments
POST /payments/subscription
POST /payments/event
{
user: id of the user
conektaId: id of conekta order if conekta was used
concept:
date:date of payment
amount: 10000
paid:false
paymentType:enum:['Subscription', 'Event']
recipetURL:String
}
<a name="datos-facturacion"></a>
GET /dataFacturacion
POST /dataFacturacion
PATCH /dataFacturacion/id
{
user:ID
membershipSerie: String,
membershipSerieFolio: String,
membershipSerieDescription: String,
eventSerie: String,
eventSerieFolio: String,
eventSerieDescription: String,
privateNumber: String,
certificate: String,
rfc: String,
name: String,
regime: String,
zipCode: String,
cerURL: String,
keyURL: String,
}
## Files
cer
key