Επιστροφή

 

API calls & Responses

       

 

  • paths
     
    {
    • /{lang}/categories
       
      {
      • get
         
        {
        • tags
           
          [
          • "Categories"
          ],
        • summary"All the root categories",
        • description" Categories with negative ids are fixed
        • and are common for all areas/api-keys.
        • The fixed categories are as described below:
        • -1: Σημεία ενδιαφέροντος
        • -2: Χρήσιμα Τηλέφωνα
        • -3: Φαρμακεία
        • -4: Παρκινγκ ΑΜΕΑ
        • -5: Νοσοκομεία ",
        • operationId"root-category-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of category objects * <b>Test</b>",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id-1,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-map-marker",
                    • name"Σημεία Ενδιαφέροντος",
                    • description""
                    },
                  •  
                    {
                    • id-2,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-phone",
                    • name"Χρήσιμα Τηλέφωνα",
                    • description""
                    },
                  •  
                    {
                    • id-3,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-plus-square",
                    • name"Φαρμακεία",
                    • description""
                    },
                  •  
                    {
                    • id-5,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-hospital-o",
                    • name"Νοσοκομεία",
                    • description""
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/categories/{categoryId}/subcategories
       
      {
      • get
         
        {
        • tags
           
          [
          • "Categories"
          ],
        • summary"All the subcategories of the given category",
        • operationId"subcategory-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/categoryId"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra
            • resources to include Available values:<ul>
            • <li><b>subcategories</b>: The subcategories
            • of each subcategory</li> </ul>",
            • requiredfalse,
            • type"array",
            • items
               
              {
              • type"string",
              • default"subcategories",
              • enum
                 
                [
                • "subcategories"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of subcategory objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id-1,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-map-marker",
                    • name"Σημεία Ενδιαφέροντος",
                    • description""
                    },
                  •  
                    {
                    • id-2,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-phone",
                    • name"Χρήσιμα Τηλέφωνα",
                    • description""
                    },
                  •  
                    {
                    • id-3,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-plus-square",
                    • name"Φαρμακεία",
                    • description""
                    },
                  •  
                    {
                    • id-5,
                    • imagenull,
                    • iconnull,
                    • icon_class"fa fa-hospital-o",
                    • name"Νοσοκομεία",
                    • description""
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/pages/{pageSlug}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Pages"
          ],
        • summary"The page with the given slug",
        • description"The fixed slugs are: <ul> <li>
        • <b>contact</b>: Contact page</li> </ul>",
        • operationId"page-by-slug",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/pageSlug"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The page object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id12,
                    • name"Contact Page",
                    • description"<h1>Contact Page</h1>"
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/categories/{categoryId}/pois
       
      {
      • get
         
        {
        • tags
           
          [
          • "Pois"
          ],
        • summary"All the pois (including pois of subcategories)
        • of the given category",
        • operationId"poi-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/categoryId"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra
            • resources to include Available values:<ul> <li><b>categories</b>:
            • The categories the poi belongs to</li> <li><b>categories.parent_category</b>:
            • The parent_category of the category,</li> </ul>",
            • requiredfalse,
            • type"array",
            • items
               
              {
              • type"string",
              • default"categories",
              • enum
                 
                [
                • "categories",
                • "categories.parent_category"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of poi objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id522,
                    • category_id
                       
                      [
                      • -3
                      ],
                    • imagenull,
                    • name"Σ.Φ. ΣΑΡΙΔΑΚΗΣ Κ. & Ο. Ο.Ε.",
                    • address"ΛΕΥΘΕΡΑΙΟΥ 8 & ΣΜΠΩΚΟΥ:ΔΙΠΛΑ
                    • ΑΠΟ ΑLPHA BANK ΜΑΣΤΑΜΠΑΣ - ΠΕΤΑΛΟΕΙΔΗΣ",
                    • description"",
                    • contact_details
                       
                      {
                      • phone"2811103195",
                      • faxnull,
                      • sitenull,
                      • emailnull
                      },
                    • coordinates
                       
                      {
                      • lat"35.327063",
                      • lng"25.128417"
                      },
                    • dates
                       
                      {
                      • duty_dates
                         
                        [
                        •  
                          {
                          • slot"08:30 - 23:00",
                          • dates
                             
                            [
                            • "2018-12-31"
                            ]
                          },
                        •  
                          {
                          • slot"08:30 - 21:00",
                          • dates
                             
                            [
                            • "2018-12-31",
                            • "2019-01-01"
                            ]
                          },
                        •  
                          {
                          • slot"08:30 - 14:00 & 17:30 - 00:00",
                          • dates
                             
                            [
                            • "2018-12-31"
                            ]
                          }
                        ],
                      • overnight_duty_dates
                         
                        [
                        •  
                          {
                          • slot"08:30 - 22:00",
                          • dates: [ ]
                          }
                        ]
                      },
                    • extended_duty_days
                       
                      [
                      • "mon",
                      • "wed",
                      • "sat"
                      ]
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/pois/{poiId}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Pois"
          ],
        • summary"Return the poi with the given id",
        • operationId"poi-item",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/poiId"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include
            • Available values:<ul> <li><b>categories</b>:
            • The categories the poi belongs to</li>
            • <li><b>categories.parent_category</b>:
            • The parent_category of the category,</li> </ul>",
            • requiredfalse,
            • type"array",
            • items
               
              {
              • type"string",
              • default"categories",
              • enum
                 
                [
                • "categories",
                • "categories.parent_category"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of poi objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id522,
                  • category_id
                     
                    [
                    • -3
                    ],
                  • imagenull,
                  • name"Σ.Φ. ΣΑΡΙΔΑΚΗΣ Κ. & Ο. Ο.Ε.",
                  • address"ΛΕΥΘΕΡΑΙΟΥ 8 & ΣΜΠΩΚΟΥ:ΔΙΠΛΑ ΑΠΟ ΑLPHA
                  • BANK ΜΑΣΤΑΜΠΑΣ - ΠΕΤΑΛΟΕΙΔΗΣ",
                  • description"",
                  • contact_details
                     
                    {
                    • phone"2811103195",
                    • faxnull,
                    • sitenull,
                    • emailnull
                    },
                  • coordinates
                     
                    {
                    • lat"35.327063",
                    • lng"25.128417"
                    },
                  • dates
                     
                    {
                    • duty_dates
                       
                      [
                      •  
                        {
                        • slot"08:30 - 23:00",
                        • dates
                           
                          [
                          • "2018-12-31"
                          ]
                        },
                      •  
                        {
                        • slot"08:30 - 21:00",
                        • dates
                           
                          [
                          • "2018-12-31",
                          • "2019-01-01"
                          ]
                        },
                      •  
                        {
                        • slot"08:30 - 14:00 & 17:30 - 00:00",
                        • dates
                           
                          [
                          • "2018-12-31"
                          ]
                        }
                      ],
                    • overnight_duty_dates
                       
                      [
                      •  
                        {
                        • slot"08:30 - 22:00",
                        • dates: [ ]
                        }
                      ]
                    },
                  • extended_duty_days
                     
                    [
                    • "mon",
                    • "wed",
                    • "sat"
                    ]
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/passwordForgot
       
      {
      • post
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"Reset Password",
        • operationId"reset-password",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"email",
            • in"formData",
            • description"Email address",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successfull operation",
            • examples
               
              {
              • data
                 
                {
                • message"Check your email, to follow
                • the link that will allow you to
                • reset your password! Please check the SPAM folder,
                • if you can't find it inside your inbox!"
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email has already been taken."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/login
       
      {
      • post
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"Login",
        • operationId"login",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"email",
            • in"query",
            • description"email address",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"password",
            • in"query",
            • description"",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • token"token_value",
                • user
                   
                  {
                  • id"6es8PKsRbf6fifXW65uoVwd4yqxhpjeJzwNzwWk2",
                  • username"[email protected]",
                  • name"Dotsoft Test User"
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email field is required."
                  ],
                • password
                   
                  [
                  • "The password field is required."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/eform/categories
       
      {
      • get
         
        {
        • tags
           
          [
          • "Eforms"
          ],
        • summary"Return the whole nested tree of eform categories",
        • operationId"eforms-catalog-category",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"A nested array of category objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id4,
                    • name"CATEGORY A",
                    • updated_at"2019-05-17 11:58:34",
                    • children
                       
                      {
                      • data: [ ]
                      }
                    },
                  •  
                    {
                    • id8,
                    • name"Κατηγορία Β",
                    • updated_at"2019-05-30 10:31:21",
                    • children
                       
                      {
                      • data: [ ]
                      }
                    },
                  •  
                    {
                    • id9,
                    • name"Κατηγορία Γ",
                    • updated_at"2019-05-30 10:31:33",
                    • children
                       
                      {
                      • data: [ ]
                      }
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/eform/statuses
       
      {
      • get
         
        {
        • tags
           
          [
          • "Eforms"
          ],
        • summary"Return a list of possible statuses for an eform,
        • with entries in the form status_id: status_label.",
        • operationId"eforms-catalog-status",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An object with status codes (status_id)
            • as keys and labels (status) as objects",
            • examples
               
              {
              • application/json
                 
                [
                • "Αδημοσίευτη",
                • "Δημοσιευμένη",
                • "Αποσυρμένη"
                ]
              }
            },
          • 401
             
            {
            • description"Unauthorized"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/categories/certificates
       
      {
      • get
         
        {
        • tags
           
          [
          • "Certificates"
          ],
        • summary"Return a list of certificate categories",
        • operationId"certificate-category-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of category objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id1,
                    • name"Δημοτολόγια"
                    },
                  •  
                    {
                    • id2,
                    • name"Ληξιαρχεία"
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/categories/problems
       
      {
      • get
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Return a list of problem report categories",
        • operationId"certificate-problem-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"employee_only",
            • in"query",
            • description"Boolean value denoting whether you want
            • categories visible by employees only or not",
            • requiredfalse,
            • type"boolean"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of category objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id3,
                    • name"Απορρίματα",
                    • login_requiredtrue
                    },
                  •  
                    {
                    • id4,
                    • name"Παιδικές Χαρές",
                    • login_requiredtrue
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/certificates/{category_id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Certificates"
          ],
        • summary"Return a list of certificates",
        • operationId"certificate-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"category_id",
            • in"path",
            • description"The id of the category that we want certificates of",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of certificate objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id1,
                    • name"Ληξιαρχική Πράξη Γεννήσεως",
                    • description"",
                    • fields
                       
                      [
                      •  
                        {
                        • infonull,
                        • type"test",
                        • group"",
                        • label"Αριθμός Ταυτότητας",
                        • requiredtrue
                        }
                      ]
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/{certificate_id}/certificates
       
      {
      • post
         
        {
        • tags
           
          [
          • "Certificates"
          ],
        • summary"Allow a cityzen to submit a request for a certificate",
        • operationId"certificate-request-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"certificate_id",
            • in"query",
            • description"The id of the certificate that the request is for",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • name"input",
            • in"path",
            • description"The json array of the fields as returned
            • by the according certificate endpoint. Each object in
            • the array should have an extra key named 'value' with
            • the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with
            • the validation error and value is an array of validation
            • error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/certificate_requests
       
      {
      • get
         
        {
        • tags
           
          [
          • "Certificates"
          ],
        • summary"Return a list of certificate requests submitted by this registered user",
        • operationId"certificate-request-user-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"certificate",
              • enum
                 
                [
                • "owner_comments",
                • "certificate"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • name"status_filter",
            • in"query",
            • description"comma separated list of status filters
            • (or condition applied for multiple values)",
            • type"array",
            • items
               
              {
              • type"string",
              • enum
                 
                [
                • "status_submitted",
                • "status_assigned",
                • "status_working_on",
                • "status_completed",
                • "status_archived"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of certificate request objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id"2018-1",
                    • certificate_id2,
                    • input
                       
                      [
                      •  
                        {
                        • id"8yad209gf3h",
                        • value"ΑΒ1234"
                        }
                      ],
                    • status"Προς διεκπεραίωση",
                    • created_at"2018-02-01 14:04:51",
                    • owner_comments
                       
                      {
                      • data: [ ]
                      },
                    • certificate
                       
                      {
                      • data
                         
                        {
                        • id2,
                        • name"Ληξιαρχική Πράξη Γάμου",
                        • description"",
                        • fields
                           
                          [
                          •  
                            {
                            • id"8yad209gf3h",
                            • infonull,
                            • type"text",
                            • groupnull,
                            • label"Αριθμός Ταυτότητας",
                            • requiredtrue
                            }
                          ]
                        }
                      }
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/certificate_requests/{$id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Certificates"
          ],
        • summary"Return the certificate request with the given id
        • submitted by this user",
        • operationId"certificate-request-user-show",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"the id of the request",
            • type"string"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra
            • resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"certificate",
              • enum
                 
                [
                • "owner_comments",
                • "certificate"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The certificate request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2018-1",
                  • certificate_id2,
                  • input
                     
                    [
                    •  
                      {
                      • id"8yad209gf3h",
                      • value"ΑΒ1234"
                      }
                    ],
                  • status"Προς διεκπεραίωση",
                  • created_at"2018-02-01 14:04:51",
                  • owner_comments
                     
                    {
                    • data: [ ]
                    },
                  • certificate
                     
                    {
                    • data
                       
                      {
                      • id2,
                      • name"Ληξιαρχική Πράξη Γάμου",
                      • description"",
                      • fields
                         
                        [
                        •  
                          {
                          • id"8yad209gf3h",
                          • infonull,
                          • type"text",
                          • groupnull,
                          • label"Αριθμός Ταυτότητας",
                          • requiredtrue
                          }
                        ]
                      }
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 404
             
            {
            • description"invalid id"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/user
       
      {
      • get
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"Get the user info",
        • operationId"profile",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • message"Check you email address,
                • in order to complete your registration!"
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email has already been taken."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        },
      • post
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"Update the user info",
        • operationId"profile-update",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • message"Check you email address,
                • in order to complete your registration!"
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email has already been taken."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/crews/login
       
      {
      • post
         
        {
        • tags
           
          [
          • "Crew Members"
          ],
        • summary"Login",
        • operationId"crew login",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"email",
            • in"formData",
            • description"email address",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"password",
            • in"formData",
            • description"",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • token"token_value",
                • user
                   
                  {
                  • id"6es8PKsRbf6fifXW65uoVwd4yqxhpjeJzwNzwWk2",
                  • username"[email protected]",
                  • name"Dotsoft Test User"
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email field is required."
                  ],
                • password
                   
                  [
                  • "The password field is required."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/employees/login
       
      {
      • post
         
        {
        • tags
           
          [
          • "Employees"
          ],
        • summary"Login",
        • operationId"employee login",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"email",
            • in"formData",
            • description"email address",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"password",
            • in"formData",
            • description"",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • token"token_value",
                • user
                   
                  {
                  • id"6es8PKsRbf6fifXW65uoVwd4yqxhpjeJzwNzwWk2",
                  • username"[email protected]",
                  • name"Dotsoft Test User"
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email field is required."
                  ],
                • password
                   
                  [
                  • "The password field is required."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/infrastructures
       
      {
      • post
         
        {
        • tags
           
          [
          • "Infrastructures"
          ],
        • summary"Anonymous submit of a new infrastructure",
        • operationId"infrastructure-submit-anonymous",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"infrastructure_type_id",
            • in"formData",
            • description"The id of the infrastructure type",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • name"lat",
            • in"formData",
            • description"latitude of the infrastructure",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"lng",
            • in"formData",
            • description"longitude of the infrastructure",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"image",
            • in"formData",
            • description"base64 representation of an image",
            • requiredfalse,
            • type"string"
            },
          •  
            {
            • name"values",
            • in"formData",
            • description"The json array of the fields as returned by the
            • according infrastructure fields endpoint. Each object in the
            • array should have an extra key named 'value' with the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The infrastructure object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • image"image.jpeg",
                  • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                  • address"Αλμπερτ Σβαιτσερ 12",
                  • coordinates
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field
            • with the validation error and value is an array of
            • validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/infrastructureTypes
       
      {
      • get
         
        {
        • tags
           
          [
          • "Infrastructures"
          ],
        • summary"Return a list of infrastructure types",
        • operationId"infrastructure-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of infrastructure objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id1,
                    • name"Ιστοί οδοφωτισμού και φωτιστικά σώματα",
                    • description"",
                    • fields
                       
                      [
                      •  
                        {
                        • infonull,
                        • type"list",
                        • extra
                           
                          {
                          • multiplefalse,
                          • values
                             
                            [
                            • "ΗΡΑΚΛΕΙΟΥ",
                            • "ΓΟΡΓΟΛΑΪΝΗ",
                            • "ΝΕΑΣ ΑΛΙΚΑΡΝΑΣΣΟΥ",
                            • "ΠΑΛΙΑΝΗΣ",
                            • "ΤΕΜΕΝΟΥΣ"
                            ]
                          },
                        • group"",
                        • label" Δημοτική Ενότητα",
                        • requiredfalse
                        },
                      •  
                        {
                        • infonull,
                        • type"text",
                        • groupnull,
                        • label"Ονομασία οδού – πεζόδρομου – πλατείας - πάρκου",
                        • requiredfalse
                        },
                      •  
                        {
                        • infonull,
                        • type"range",
                        • extra
                           
                          {
                          • to"15",
                          • from"1",
                          • step"1"
                          },
                        • group"Στοιχεία ιστού",
                        • label"Αριθμός φωτιστικών σωμάτων ανά ιστό",
                        • requiredfalse
                        }
                      ]
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/reports/fields
       
      {
      • get
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Return a list of fields to be used when submitting a problem report",
        • description"The superset of available fields is: <ul> <li><b>category_id (integer)
        • </b>:The id of the category that the report is for</li> <li><b>description (string)
        • </b>:The description of the problem</li> <li><b>address (string)</b>:The address
        • near where the problem occurred</li> <li><b>lat (string)</b>:Latitude of the
        • occurence</li> <li><b>lng (string)</b>:Longitude of the occurence</li> <li>
        • <b>image (string)</b>:base64 representation of an image of the problem of
        • the occurence</li> </ul>",
        • operationId"problem-report-field-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of fields. If the fields has a list of
            • acceptable values, then 'value_list' will be shown populated with
            • this values",
            • examples
               
              {
              • data
                 
                [
                •  
                  {
                  • field"category_id",
                  • requiredtrue,
                  • label"Κατηγορία"
                  },
                •  
                  {
                  • field"description",
                  • requiredtrue,
                  • label"Περιγραφή"
                  },
                •  
                  {
                  • field"address",
                  • requiredfalse,
                  • label"Διεύθυνση"
                  },
                •  
                  {
                  • field"lat",
                  • requiredtrue,
                  • label"lat"
                  },
                •  
                  {
                  • field"lng",
                  • requiredtrue,
                  • label"lng"
                  },
                •  
                  {
                  • field"image",
                  • requiredfalse,
                  • label"Εικόνα"
                  }
                ]
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/{category_id}/reports
       
      {
      • post
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Allow a registered cityzen to submit a problem report. You should
        • send the fields returned by the fields endpoint. If some are required
        • and not set, you' ll get the according error response.",
        • operationId"cityzen-report-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"category_id",
            • in"path",
            • description"The id of the category that the report is for",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The report object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • image"image.jpeg",
                  • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                  • address"Αλμπερτ Σβαιτσερ 12",
                  • coordinates
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/{category_id}/reports/unregistered
       
      {
      • post
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Allow an unregistered cityzen to submit a problem report.
        • Apart from the fields described below, you should also send the fields
        • returned by the fields endpoint. If some are required and not set,
        • you' ll get the according error response.",
        • operationId"unregistered-cityzen-report-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"category_id",
            • in"path",
            • description"The id of the category that the report is for",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • name"firstname",
            • in"formData",
            • description"The cityzen's firstname",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"lastname",
            • in"formData",
            • description"The cityzen's lastname",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"phone",
            • in"formData",
            • description"The cityzen's phone number",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"email",
            • in"formData",
            • description"The cityzen's email",
            • requiredfalse,
            • type"string"
            },
          •  
            {
            • name"cityzen_address",
            • in"formData",
            • description"The cityzen's address",
            • requiredfalse,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The report object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • image"image.jpeg",
                  • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                  • address"Αλμπερτ Σβαιτσερ 12",
                  • coordinates
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/reports
       
      {
      • get
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Return a list of problem reports submitted by this registered user",
        • operationId"problem-report-user-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"owner_comments",
              • enum
                 
                [
                • "owner_comments"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • name"status_filter",
            • in"query",
            • description"comma separated list of status filters (or
            • condition applied for multiple values)",
            • type"array",
            • items
               
              {
              • type"string",
              • enum
                 
                [
                • "status_submitted",
                • "status_assigned",
                • "status_working_on",
                • "status_completed",
                • "status_archived"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of problem report objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id"2018-1",
                    • image"image.jpeg",
                    • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                    • address"Αλμπερτ Σβαιτσερ 12",
                    • coordinates
                       
                      {
                      • lat"35.339055",
                      • lng"25.133114200000023"
                      },
                    • status"Ανατέθηκε",
                    • owner_comments
                       
                      {
                      • data
                         
                        [
                        •  
                          {
                          • comment"OK το κοιτάμε",
                          • created_at"2018-02-14 10:54:53"
                          }
                        ]
                      },
                    • created_at"2018-02-01 12:50:32"
                    },
                  •  
                    {
                    • id"2018-2",
                    • image"image.jpeg",
                    • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                    • address"Αλμπερτ Σβαιτσερ 12",
                    • coordinates
                       
                      {
                      • lat"35.339055",
                      • lng"25.133114200000023"
                      },
                    • status"Ανατέθηκε",
                    • owner_comments
                       
                      {
                      • data: [ ]
                      },
                    • created_at"2018-02-01 12:53:40"
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/reports/{$id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Problem Reports"
          ],
        • summary"Return the problem report with the given id submitted by this user",
        • operationId"problem-report-user-show",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"the id of the report",
            • type"string"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"owner_comments",
              • enum
                 
                [
                • "owner_comments"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The report object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2018-1",
                  • image"image.jpeg",
                  • description"Υπάρχει πρόβλημα με λακούβα στο δρόμο",
                  • address"Αλμπερτ Σβαιτσερ 12",
                  • coordinates
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    },
                  • status"Ανατέθηκε",
                  • owner_comments
                     
                    {
                    • data
                       
                      [
                      •  
                        {
                        • comment"OK το κοιτάμε",
                        • created_at"2018-02-14 10:54:53"
                        }
                      ]
                    },
                  • created_at"2018-02-01 12:50:32"
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 404
             
            {
            • description"invalid id"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/user/registrationFields
       
      {
      • get
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"The fields that are presented on the registration form
        • of a new user (apart from email,password)",
        • operationId"registration_fields",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of fields. If the fields has a list of
            • acceptable values, then 'value_list' will be shown populated
            • with this values",
            • examples
               
              {
              • data
                 
                [
                •  
                  {
                  • field"name",
                  • type"text",
                  • requiredtrue,
                  • label"Fullname"
                  },
                •  
                  {
                  • field"municipal_section",
                  • type"list",
                  • requiredfalse,
                  • label"Municipal Section",
                  • value_list
                     
                    [
                    • "Section 1",
                    • "Section 2"
                    ]
                  }
                ]
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/user/register
       
      {
      • post
         
        {
        • tags
           
          [
          • "Users"
          ],
        • summary"Register with the extra fields returned by registrationFields
        • endpoint. Apart from the fields shown below you can also send all the other
        • fields returned by the previous endpoint. If some are required and not set,
        • you' ll get the according error response.",
        • operationId"register",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"email",
            • in"formData",
            • description"Email address",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"password",
            • in"formData",
            • description"Password",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"successful operation",
            • schema
               
              {
              • properties
                 
                {
                • token
                   
                  {
                  • type"string"
                  },
                • user
                   
                  {
                  • type"object"
                  }
                }
              },
            • examples
               
              {
              • data
                 
                {
                • message"Check you email address, in order to
                • complete your registration!"
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"invalid parameter values",
            • examples
               
              {
              • error
                 
                {
                • email
                   
                  [
                  • "The email has already been taken."
                  ]
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/tasks
       
      {
      • get
         
        {
        • tags
           
          [
          • "Work Orders"
          ],
        • summary"Return a list of work orders that are assigned to the user",
        • operationId"task-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"input",
              • enum
                 
                [
                • "input",
                • "report"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • name"status_filter",
            • in"query",
            • description"comma separated list of status filters (or condition
            • applied for multiple values)",
            • type"array",
            • items
               
              {
              • type"string",
              • enum
                 
                [
                • "status_pending",
                • "status_read",
                • "status_in_progress",
                • "status_success",
                • "status_error"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of task objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id6,
                    • name"test2",
                    • info"test2",
                    • deadline"2018-02-14",
                    • priority"Υψηλή",
                    • status"Σε διαδικασία χειρισμού",
                    • updated_at"2018-03-13 10:22:12",
                    • files
                       
                      [
                      •  
                        {
                        • url"image.png",
                        • mime"image/png",
                        • caption""
                        }
                      ],
                    • input
                       
                      {
                      • data
                         
                        [
                        •  
                          {
                          • user"Συνεργείο1 Heraklion",
                          • comment"asa",
                          • image"image.png",
                          • created_at"2018-02-13 13:18:04"
                          }
                        ]
                      }
                    },
                  •  
                    {
                    • id5,
                    • name"Εργασία 1",
                    • info"Πάρε να χεις2",
                    • deadline"2018-03-10",
                    • priority"Κανονική",
                    • status"Εκκρεμεί",
                    • files: [ ],
                    • comments
                       
                      {
                      • data: [ ]
                      }
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/tasks/{id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Work Orders"
          ],
        • summary"Return a specific workorder",
        • operationId"task-show",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"the id of the workorder",
            • type"string"
            },
          •  
            {
            • name"include",
            • in"query",
            • description"comma separated list of extra resources to include",
            • type"array",
            • items
               
              {
              • type"string",
              • default"input",
              • enum
                 
                [
                • "input",
                • "report"
                ]
              },
            • collectionFormat"csv"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of task objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id6,
                    • name"test2",
                    • info"test2",
                    • deadline"2018-02-14",
                    • priority"Υψηλή",
                    • status"Σε διαδικασία χειρισμού",
                    • updated_at"2018-03-13 10:22:12",
                    • files
                       
                      [
                      •  
                        {
                        • url"image.png",
                        • mime"image/png",
                        • caption""
                        }
                      ],
                    • input
                       
                      {
                      • data
                         
                        [
                        •  
                          {
                          • user"Συνεργείο1 Heraklion",
                          • comment"asa",
                          • image"image.png",
                          • created_at"2018-02-13 13:18:04"
                          }
                        ]
                      }
                    },
                  •  
                    {
                    • id5,
                    • name"Εργασία 1",
                    • info"Πάρε να χεις2",
                    • deadline"2018-03-10",
                    • priority"Κανονική",
                    • status"Εκκρεμεί",
                    • files: [ ],
                    • comments
                       
                      {
                      • data: [ ]
                      }
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /lang}/municipalities/tasks/{id}
       
      {
      • post
         
        {
        • tags
           
          [
          • "Work Orders"
          ],
        • summary"Allow a crew member to update a certain work order",
        • operationId"task-update",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"query",
            • description"The id of the task",
            • requiredtrue,
            • type"integer"
            },
          •  
            {
            • name"status",
            • in"formData",
            • description"The status of the task.
            • Available values:
            • {status_pending,status_read,status_in_progress,
            • status_success,status_error}",
            • requiredfalse,
            • type"string",
            • enum
               
              [
              • "status_pending",
              • "status_read",
              • "status_in_progress",
              • "status_success",
              • "status_error"
              ]
            },
          •  
            {
            • name"comment",
            • in"path",
            • description"A comment",
            • requiredfalse,
            • type"string"
            },
          •  
            {
            • name"image",
            • in"path",
            • description"base64 representation of an image to
            • accompany the comment",
            • requiredfalse,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The task object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id6,
                  • name"test2",
                  • info"test2",
                  • deadline"2018-02-14",
                  • priority"Υψηλή",
                  • status"Διεκπεραιωμένο - επιτυχώς",
                  • files
                     
                    [
                    •  
                      {
                      • url"image.png",
                      • mime"image/png",
                      • caption""
                      }
                    ],
                  • input
                     
                    {
                    • data
                       
                      [
                      •  
                        {
                        • user"Συνεργείο1 Heraklion",
                        • comment"test",
                        • image"image.png",
                        • created_at"2018-02-15 11:55:36"
                        },
                      •  
                        {
                        • user"Συνεργείο1 Heraklion",
                        • comment"test",
                        • imagenull,
                        • created_at"2018-02-15 11:53:25"
                        },
                      •  
                        {
                        • user"Συνεργείο1 Heraklion",
                        • comment"asa",
                        • image"image.png",
                        • created_at"2018-02-13 13:18:04"
                        }
                      ]
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with
            • the validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/municipalities/tasks/status
       
      {
      • get
         
        {
        • tags
           
          [
          • "Work Orders"
          ],
        • summary"Return a list of possible statuses for a work order",
        • operationId"task-status-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"A object with status codes as keys and labels as objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id6,
                    • name"test2",
                    • info"test2",
                    • deadline"2018-02-14",
                    • priority"Υψηλή",
                    • status"Σε διαδικασία χειρισμού",
                    • files
                       
                      [
                      •  
                        {
                        • url"image.png",
                        • mime"image/png",
                        • caption""
                        }
                      ],
                    • input
                       
                      {
                      • data
                         
                        [
                        •  
                          {
                          • user"Συνεργείο1 Heraklion",
                          • comment"asa",
                          • image"image.png",
                          • created_at"2018-02-13 13:18:04"
                          }
                        ]
                      }
                    },
                  •  
                    {
                    • id5,
                    • name"Εργασία 1",
                    • info"Πάρε να χεις2",
                    • deadline"2018-03-10",
                    • priority"Κανονική",
                    • status"Εκκρεμεί",
                    • files: [ ],
                    • comments
                       
                      {
                      • data: [ ]
                      }
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid user"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/notifications
       
      {
      • get
         
        {
        • tags
           
          [
          • "Notifications"
          ],
        • summary"Return a list of notifications for this specific user",
        • operationId"notification-list",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            },
          •  
            {
            • name"read_filter",
            • in"query",
            • description"If true only read notification retrieved.
            • If false only unread are retrieved. In not set all are retrieved",
            • type"boolean"
            },
          •  
            {
            • name"created_at_filter",
            • in"query",
            • description"The bottom limit date, since when we want
            • to retrieve dates. The format is YYYY-MM-DD HH:mm e.g 2018-12-31 23:59",
            • type"string"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The list of notifications",
            • examples
               
              {
              • data
                 
                [
                •  
                  {
                  • id"de8d1238-4e99-43de-bf90-353b943cc3a1",
                  • type"work_order_new_comment",
                  • title"Νεό σχόλιο σε εντολή εργασίας",
                  • body"τι θα γίνει ρε Νταλάρα?",
                  • data
                     
                    {
                    • id50
                    },
                  • created_at"2018-10-10 10:07:37",
                  • read_atnull
                  },
                •  
                  {
                  • id"205dc075-b0cc-45f2-be48-3cc9e51fa69e",
                  • type"task_new",
                  • title"Νέα Εργασία",
                  • body"νέα εργασία",
                  • data
                     
                    {
                    • id9
                    },
                  • created_at"2018-10-08 13:44:45",
                  • read_atnull
                  }
                ]
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/notifications/{id}/read
       
      {
      • post
         
        {
        • tags
           
          [
          • "Notifications"
          ],
        • summary"Allow a registered user to mark a notification as read",
        • operationId"notification-mark-read",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"The id of the notification",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The notification object",
            • examples
               
              {
              • application/json
                 
                {
                • data: [ ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/questionnaires
       
      {
      • get
         
        {
        • tags
           
          [
          • "Questionnaires"
          ],
        • summary"Return a list of questionnaires",
        • operationId"questionnaire-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of questionnaire objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id1,
                    • name"Ερωτηματολόγιο",
                    • description"",
                    • fields
                       
                      [
                      •  
                        {
                        • infonull,
                        • type"text",
                        • group"",
                        • label"Όνομα",
                        • requiredtrue
                        }
                      ]
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/questionnaires/{id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Questionnaires"
          ],
        • summary"Return a specific questionnaire",
        • operationId"questionnaire-show",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"The id of the questionnaire",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"A questionnaire object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id1,
                  • name"Ερωτηματολόγιο",
                  • description"",
                  • fields
                     
                    [
                    •  
                      {
                      • infonull,
                      • type"text",
                      • group"",
                      • label"Όνομα",
                      • requiredtrue
                      }
                    ]
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/questionnaires/{questionnaire_id}/input
       
      {
      • get
         
        {
        • tags
           
          [
          • "Questionnaires"
          ],
        • summary"Get all fill-ins of the cityzen for the given questionnaire",
        • operationId"questionnaire-fill-in-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"questionnaire_id",
            • in"path",
            • description"The id of the questionnaire that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        },
      • post
         
        {
        • tags
           
          [
          • "Questionnaires"
          ],
        • summary"Allow a cityzen to fill in a questionnaire",
        • operationId"questionnaire-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"questionnaire_id",
            • in"path",
            • description"The id of the questionnaire that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"input",
            • in"path",
            • description"The json array of the fields as returned by the
            • according questionnaire endpoint. Each object in the array should
            • have an extra key named 'value' with the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/questionnaires/{questionnaire_id}/input/unregistered
       
      {
      • post
         
        {
        • tags
           
          [
          • "Questionnaires"
          ],
        • summary"Allow an unregistered user to fill in a questionnaire",
        • operationId"unregistered-questionnaire-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"questionnaire_id",
            • in"path",
            • description"The id of the questionnaire that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"input",
            • in"path",
            • description"The json array of the fields as returned by the
            • according questionnaire endpoint. Each object in the array should
            • have an extra key named 'value' with the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/services
       
      {
      • get
         
        {
        • tags
           
          [
          • "Services"
          ],
        • summary"Return a list of services",
        • operationId"service-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"An array of service objects",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  [
                  •  
                    {
                    • id1,
                    • name"Υπηρεσία 1",
                    • description"",
                    • fields
                       
                      [
                      •  
                        {
                        • infonull,
                        • type"text",
                        • group"",
                        • label"Όνομα",
                        • requiredtrue
                        }
                      ]
                    }
                  ]
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/services/{id}
       
      {
      • get
         
        {
        • tags
           
          [
          • "Services"
          ],
        • summary"Return a specific service",
        • operationId"service-show",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"id",
            • in"path",
            • description"The id of the service",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"A Service object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id1,
                  • name"Υπηρεσία",
                  • description"",
                  • fields
                     
                    [
                    •  
                      {
                      • infonull,
                      • type"text",
                      • group"",
                      • label"Όνομα",
                      • requiredtrue
                      }
                    ]
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/services/{service_id}/input
       
      {
      • get
         
        {
        • tags
           
          [
          • "Services"
          ],
        • summary"Get all requests of the cityzen for the given Service",
        • operationId"Service-request-index",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"Service_id",
            • in"path",
            • description"The id of the Service that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        },
      • post
         
        {
        • tags
           
          [
          • "Services"
          ],
        • summary"Allow a user to submit a service request",
        • operationId"Service-request-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"service_id",
            • in"path",
            • description"The id of the service that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"input",
            • in"path",
            • description"The json array of the fields as returned by the
            • according service endpoint. Each object in the array should have an
            • extra key named 'value' with the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },
          • 401
             
            {
            • description"invalid api key"
            },
          • 422
             
            {
            • description"Validation errors. Key is the field with the
            • validation error and value is an array of validation error messages",
            • examples
               
              {
              • application/json
                 
                {
                • error
                   
                  {
                  • lat
                     
                    [
                    • "A value is required for field lat.",
                    • "lat must be a number."
                    ]
                  }
                }
              }
            },
          • 500
             
            {
            • description"internal server error"
            }
          }
        }
      },
    • /{lang}/services/{service_id}/input/unregistered
       
      {
      • post
         
        {
        • tags
           
          [
          • "Services"
          ],
        • summary"Allow an unregistered user to request a service",
        • operationId"unregistered-service-request-submit",
        • parameters
           
          [
          •  
            {
            • $ref"#/parameters/lang"
            },
          •  
            {
            • name"Service_id",
            • in"path",
            • description"The id of the service that the request is for",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • name"input",
            • in"path",
            • description"The json array of the fields as returned by the
            • according service endpoint. Each object in the array should have an
            • extra key named 'value' with the according field value",
            • requiredtrue,
            • type"string"
            },
          •  
            {
            • $ref"#/parameters/X-Authorization"
            }
          ],
        • responses
           
          {
          • 200
             
            {
            • description"The request object",
            • examples
               
              {
              • application/json
                 
                {
                • data
                   
                  {
                  • id"2017-1",
                  • input
                     
                    {
                    • lat"35.339055",
                    • lng"25.133114200000023"
                    }
                  }
                }
              }
            },