{ "openapi": "3.0.0", "info": { "description": "This API allows a front-end application to interact with the calendars of sales representatives", "version": "1.0.0", "title": "Agenda API", "contact": { "email": "frpenal@microsoft.com" }, "x-jentic-source-url": "https://api.swaggerhub.com/apis/MICROSOFTPICHET/ARDV/1.0.0/swagger.json" }, "servers": [ { "url": "https://virtserver.swaggerhub.com/MICROSOFTPICHET/ARDV/1.0.0" } ], "paths": { "/appointments/{id}": { "get": { "tags": [ "appointments" ], "summary": "get appointment by ID", "description": "Retrieve an appointment by its ID\n", "operationId": "getAppointment", "parameters": [ { "name": "id", "in": "path", "description": "unique identifier for the appointment", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Appointment" } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/appointments": { "get": { "tags": [ "appointments" ], "summary": "searches appointments", "description": "By passing in the search criteria, you can search for\ncorresponding appointments in the system\n", "operationId": "searchAppointments", "parameters": [ { "name": "from", "in": "query", "description": "from date", "required": true, "schema": { "type": "string", "format": "date" } }, { "name": "to", "in": "query", "description": "to date", "required": true, "schema": { "type": "string", "format": "date" } }, { "name": "users", "in": "query", "description": "comma-separated list of user GUID", "required": true, "schema": { "type": "string", "format": "date" } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Appointment" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } }, "post": { "tags": [ "appointments" ], "summary": "creates an appointment", "description": "Adds an appointment to the system", "operationId": "createAppointment", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Appointment" } } }, "description": "Appointment to create" }, "responses": { "201": { "description": "appointment created", "content": { "application/json": { "schema": { "type": "string", "format": "uuid", "example": "549a8aa3-c349-4ab9-8bac-4873fa9a7a5c", "description": "the ID of the newly created appointment" } } } }, "400": { "description": "invalid input, object invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } }, "delete": { "tags": [ "appointments" ], "summary": "deletes an appointment", "description": "Deletes an appointment from the system", "operationId": "deleteAppointment", "responses": { "201": { "description": "appointment deleted" }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "*/*": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "*/*": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "*/*": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } }, "patch": { "tags": [ "appointments" ], "summary": "updates all the fields of an appointment", "description": "Updates an appointment into the system", "operationId": "updateAppointment", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Appointment" } } }, "description": "Appointment to update" }, "responses": { "201": { "description": "item updated" }, "400": { "description": "invalid input, object invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/appointments/{id}/close/{close_reason_id}": { "put": { "tags": [ "appointments" ], "summary": "updates the status of an appointment", "description": "Updates an appointment's status into the system", "operationId": "updateAppointmentStatus", "parameters": [ { "name": "id", "in": "path", "description": "unique identifier for the appointment", "required": true, "schema": { "type": "string", "format": "uuid" } }, { "name": "close_reason_id", "in": "path", "description": "close reason id", "required": true, "schema": { "type": "integer", "format": "int32" } } ], "responses": { "201": { "description": "item updated" }, "400": { "description": "invalid input, object invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/recurring_appointments/{id}": { "get": { "tags": [ "recurring appointments" ], "summary": "get recursion by ID", "description": "Retrieve a recusrion by its ID\n", "operationId": "getRecurringAppointment", "parameters": [ { "name": "id", "in": "path", "description": "unique identifier for the recursion", "required": true, "schema": { "type": "string", "format": "uuid" } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecurringAppointment" } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/recurring_appointments": { "post": { "tags": [ "recurring appointments" ], "summary": "creates a recurring pattern", "description": "Adds arecusrion to the system", "operationId": "createRecurringAppointment", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecurringAppointment" } } }, "description": "Recursion to create" }, "responses": { "201": { "description": "recursion created", "content": { "application/json": { "schema": { "type": "string", "format": "uuid", "example": "549a8aa3-c349-4ab9-8bac-4873fa9a7a5c", "description": "the ID of the newly created recursion" } } } }, "400": { "description": "invalid input, object invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } }, "patch": { "tags": [ "recurring appointments" ], "summary": "updates all the fields of a recursion", "description": "Updates a recursion into the system", "operationId": "updateRecurringAppointment", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RecurringAppointment" } } }, "description": "Recursion to update" }, "responses": { "201": { "description": "item updated" }, "400": { "description": "invalid input, object invalid", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "404": { "description": "id does not exist", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/metadata": { "get": { "tags": [ "metadata" ], "summary": "get application metadata", "description": "Retrieve metada such as option set values and system URL\n", "operationId": "getMetadata", "responses": { "200": { "description": "system metadata", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Metadata" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/contacts": { "get": { "tags": [ "ref data" ], "summary": "searches contacts", "description": "By passing in the search criteria, you can search for\ncorresponding contacts in the system\n", "operationId": "searchContacts", "parameters": [ { "name": "search", "in": "query", "description": "pass the search string for looking for contacts", "required": true, "schema": { "type": "string", "minLength": 3 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Contact" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/cdv": { "get": { "tags": [ "ref data" ], "summary": "searches sales cycles", "description": "By passing in the search criteria, you can search for\ncorresponding sales cycles in the system\n", "operationId": "searchCdv", "parameters": [ { "name": "search", "in": "query", "description": "pass the search string for looking for CDV", "required": true, "schema": { "type": "string", "minLength": 1 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Cdv" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/agencies": { "get": { "tags": [ "ref data" ], "summary": "searches sales agencies", "description": "By passing in the search criteria, you can search for\ncorresponding agencies in the system\n", "operationId": "searchAgency", "parameters": [ { "name": "search", "in": "query", "description": "pass the search string for looking for agency", "required": true, "schema": { "type": "string", "minLength": 1 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Agency" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/salesLocations": { "get": { "tags": [ "ref data" ], "summary": "searches sales locations", "description": "By passing in the search criteria, you can search for\ncorresponding sales locations in the system\n", "operationId": "searchLocation", "parameters": [ { "name": "search", "in": "query", "description": "pass the search string for looking for location", "required": true, "schema": { "type": "string", "minLength": 1 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/SalesLocation" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/programmes": { "get": { "tags": [ "ref data" ], "summary": "searches programmes", "description": "By passing in the search criteria, you can search for\ncorresponding programme in the system\n", "operationId": "searchProgramme", "parameters": [ { "name": "search", "in": "query", "description": "pass the search string for looking for programme", "required": true, "schema": { "type": "string", "minLength": 1 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Programme" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/cities": { "get": { "tags": [ "ref data" ], "summary": "searches cities", "description": "By passing in the search criteria, you can search for\ncorresponding cities in the system. The search contains maximum of 10 results based \n", "operationId": "searchCities", "parameters": [ { "name": "searchString", "in": "query", "description": "pass the search string for looking for cities (city name or post code)", "required": true, "schema": { "type": "string", "minLength": 3 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/City" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "403": { "description": "user does not have the permissions to perform this operation", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } }, "/sellers": { "get": { "tags": [ "ref data" ], "summary": "searches sellers", "description": "By passing in the search criteria, you can search for\ncorresponding sellers in the system\n", "operationId": "searchSellers", "parameters": [ { "name": "searchString", "in": "query", "description": "pass the search string for looking for sellers", "required": true, "schema": { "type": "string", "minLength": 3 } } ], "responses": { "200": { "description": "search results matching criteria", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/Seller" } } } } }, "400": { "description": "bad input parameter", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } }, "500": { "description": "server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Errors" } } } } } } } }, "components": { "schemas": { "Appointment": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "example": "d290f1ee-6c54-4b01-90e6-d701748f0851" }, "subject": { "type": "string", "example": "Repas" }, "start_date": { "type": "string", "format": "date-time", "example": "2016-08-29T09:12:33.001Z" }, "end_date": { "type": "string", "format": "date-time", "example": "2016-08-29T09:12:33.001Z" }, "appointment_type": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "allday": { "type": "boolean", "description": "does the appointment last all day", "example": false }, "is_commercial_type": { "type": "boolean", "description": "is it a commercial or personal appointment" }, "appointment_location": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "appointment_location_details": { "type": "string", "example": "Agence d'Andernos", "maxLength": 100 }, "appointment_street": { "type": "string", "example": "3 rue d'Albion", "maxLength": 100 }, "appointment_city": { "$ref": "#/components/schemas/City" }, "close_reason": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "is_blocked_conf": { "type": "boolean", "description": "is the appointment confirmation in progress" }, "is_reopen_possible": { "type": "boolean", "description": "true if the appointment can be reopened" }, "recurring_appointment_id": { "type": "string", "format": "uuid", "example": "3290f1ee-6c54-4b01-90e6-d701748f5341" }, "contact": { "$ref": "#/components/schemas/Contact" }, "seller": { "$ref": "#/components/schemas/Seller" }, "cdv": { "$ref": "#/components/schemas/Cdv" }, "status": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" } }, "description": "appointment between a seller and a client", "example": { "end_date": "2016-08-29T09:12:33.001Z", "is_blocked_conf": true, "seller": { "is_current_seller": true, "agency_id": "d497f1ee-6c54-4b01-90e6-d701748f646f", "last_name": "Doe", "id": "abcdf1ee-6c54-4b01-90e6-d701748f", "first_name": "Jane", "is_editable_calendar": true }, "appointment_location_details": "Agence d'Andernos", "subject": "Repas", "appointment_location": 6, "recurring_appointment_id": "3290f1ee-6c54-4b01-90e6-d701748f5341", "is_commercial_type": true, "appointment_city": { "post_code": "75001", "name": "Paris", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851" }, "is_reopen_possible": true, "cdv": { "name": "Sample CDV", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "status": 2 }, "appointment_type": 0, "contact": { "phone_preference": 5, "preferred_phone": "+33 1 24 25 54 52", "contact_street": "10 rue des fleurs", "civility": 5, "last_name": "Doe", "contact_city": { "post_code": "75001", "name": "Paris", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851" }, "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "first_name": "John", "email": "john.doe@contoso.com" }, "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "close_reason": 1, "appointment_street": "3 rue d'Albion", "start_date": "2016-08-29T09:12:33.001Z", "status": 7 } }, "RecurringAppointment": { "type": "object", "properties": { "id": { "type": "string", "format": "uuid", "example": "d290f1ee-6c54-4b01-90e6-d701748f0851" }, "subject": { "type": "string", "example": "Repas" }, "start_date": { "type": "string", "format": "date-time", "example": "2016-08-29T09:12:33.001Z" }, "end_date": { "type": "string", "format": "date-time", "example": "2017-03-29T09:12:33.001Z" }, "recurrence_pattern": { "type": "integer", "format": "int32", "description": "daily = 0 / weekly = 1" }, "interval": { "type": "integer", "format": "int32", "description": "set to 1 to repeat each day or week" }, "day_of_week": { "type": "integer", "format": "int32", "description": "Monday = 1, Tuesday = 2, etc." }, "appointment_type": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "seller": { "$ref": "#/components/schemas/Seller" } }, "description": "recurring appointment pattern", "example": { "end_date": "2017-03-29T09:12:33.001Z", "seller": { "is_current_seller": true, "agency_id": "d497f1ee-6c54-4b01-90e6-d701748f646f", "last_name": "Doe", "id": "abcdf1ee-6c54-4b01-90e6-d701748f", "first_name": "Jane", "is_editable_calendar": true }, "recurrence_pattern": 0, "appointment_type": 5, "subject": "Repas", "interval": 6, "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "start_date": "2016-08-29T09:12:33.001Z", "day_of_week": 1 } }, "Cdv": { "required": [ "id" ], "properties": { "name": { "type": "string", "example": "Sample CDV" }, "status": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "id": { "type": "string", "format": "uuid", "example": "d290f1ee-6c54-4b01-90e6-d701748f0851" } }, "description": "sales cycle (CDV) is an ongoing sales opportunity", "example": { "name": "Sample CDV", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "status": 2 } }, "Contact": { "type": "object", "required": [ "id" ], "properties": { "id": { "type": "string", "format": "uuid", "example": "d290f1ee-6c54-4b01-90e6-d701748f0851", "description": "unique identifier for the contact" }, "civility": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "first_name": { "type": "string", "example": "John" }, "last_name": { "type": "string", "example": "Doe" }, "email": { "type": "string", "format": "email", "example": "john.doe@contoso.com" }, "phone_preference": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "preferred_phone": { "type": "string", "format": "^[\\+?\\d]", "example": "+33 1 24 25 54 52" }, "contact_street": { "type": "string", "example": "10 rue des fleurs", "maxLength": 100 }, "contact_city": { "$ref": "#/components/schemas/City" } }, "description": "a contact is a client handled by a seller", "example": { "phone_preference": 5, "preferred_phone": "+33 1 24 25 54 52", "contact_street": "10 rue des fleurs", "civility": 5, "last_name": "Doe", "contact_city": { "post_code": "75001", "name": "Paris", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851" }, "id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "first_name": "John", "email": "john.doe@contoso.com" } }, "City": { "type": "object", "required": [ "id" ], "properties": { "name": { "type": "string", "example": "Paris" }, "post_code": { "type": "string", "example": "75001" }, "id": { "type": "string", "format": "uuid", "example": "d290f1ee-6c54-4b01-90e6-d701748f0851", "description": "unique identifier for the city" } }, "example": { "post_code": "75001", "name": "Paris", "id": "d290f1ee-6c54-4b01-90e6-d701748f0851" } }, "Agency": { "type": "object", "required": [ "id" ], "properties": { "name": { "type": "string", "example": "Agence d'Andernos" }, "id": { "type": "string", "format": "uuid", "example": "d497f1ee-6c54-4b01-90e6-d701748f646f", "description": "unique identifier for the agency" } }, "example": { "name": "Agence d'Andernos", "id": "d497f1ee-6c54-4b01-90e6-d701748f646f" } }, "SalesLocation": { "type": "object", "required": [ "id" ], "properties": { "name": { "type": "string", "example": "Bulle de vente de Paris" }, "location_type": { "type": "integer", "format": "int32", "description": "#/definitions/OptionSetValue" }, "id": { "type": "string", "format": "uuid", "example": "6377f1ee-6c54-4b01-90e6-d701748fa671", "description": "unique identifier for the agency" } }, "example": { "name": "Bulle de vente de Paris", "id": "6377f1ee-6c54-4b01-90e6-d701748fa671", "location_type": 0 } }, "Programme": { "type": "object", "required": [ "id" ], "properties": { "name": { "type": "string", "example": "CARRE SULLY" }, "id": { "type": "string", "format": "uuid", "example": "abcdf1ee-6c54-4b01-90e6-d701748fa985", "description": "unique identifier for the programme" } }, "example": { "name": "CARRE SULLY", "id": "abcdf1ee-6c54-4b01-90e6-d701748fa985" } }, "Seller": { "type": "object", "required": [ "id" ], "properties": { "id": { "type": "string", "format": "uuid", "example": "abcdf1ee-6c54-4b01-90e6-d701748f", "description": "unique identifier for the seller" }, "is_current_seller": { "type": "boolean", "description": "is the logged-in user" }, "is_editable_calendar": { "type": "boolean", "description": "true if seller's appointments can be modified" }, "first_name": { "type": "string", "example": "Jane" }, "last_name": { "type": "string", "example": "Doe" }, "agency_id": { "type": "string", "format": "uuid", "example": "d497f1ee-6c54-4b01-90e6-d701748f646f", "description": "unique identifier for the agency" } }, "example": { "is_current_seller": true, "agency_id": "d497f1ee-6c54-4b01-90e6-d701748f646f", "last_name": "Doe", "id": "abcdf1ee-6c54-4b01-90e6-d701748f", "first_name": "Jane", "is_editable_calendar": true } }, "Metadata": { "type": "object", "properties": { "url_template_contact": { "type": "string", "format": "url", "example": "https://pichet.crm4.dynamics.com/main.aspx?etn=contact&id=%7bCONTACTGUID%7d&pagetype=entityrecord", "description": "base string for buidling direct URL to access a CRM contact" }, "url_template_cdv": { "type": "string", "format": "url", "example": "https://pichet.crm4.dynamics.com/main.aspx?etn=opportunity&id=%7bCDVGUID%7d&pagetype=entityrecord", "description": "base string for buidling direct URL to access a CRM sales cycle" }, "default_duration": { "type": "integer", "example": 120, "description": "default duration in minutes for an appointment" }, "optionsets": { "type": "array", "description": "list of option sets in the system", "items": { "$ref": "#/components/schemas/OptionSet" } }, "sellers": { "type": "array", "description": "all the sellers whose calendar can be accessed by the current user", "items": { "$ref": "#/components/schemas/Seller" } }, "agencies": { "type": "array", "description": "all the agencies that can be accessed by the current user", "items": { "$ref": "#/components/schemas/Agency" } }, "closing_appointment_matrix": { "type": "array", "description": "table of possible options for closing appointments", "items": { "$ref": "#/components/schemas/MatrixLine" } } }, "example": { "url_template_contact": "https://pichet.crm4.dynamics.com/main.aspx?etn=contact&id=%7bCONTACTGUID%7d&pagetype=entityrecord", "url_template_cdv": "https://pichet.crm4.dynamics.com/main.aspx?etn=opportunity&id=%7bCDVGUID%7d&pagetype=entityrecord", "agencies": [ { "name": "Agence d'Andernos", "id": "d497f1ee-6c54-4b01-90e6-d701748f646f" }, { "name": "Agence d'Andernos", "id": "d497f1ee-6c54-4b01-90e6-d701748f646f" } ], "closing_appointment_matrix": [ { "next_appointment_type": 2, "appointment_type": 6, "cdv_status": 5, "closing_reason": 1, "status": 5 }, { "next_appointment_type": 2, "appointment_type": 6, "cdv_status": 5, "closing_reason": 1, "status": 5 } ], "optionsets": [ { "optionsetvalues": [ { "label": "label", "value": 0 }, { "label": "label", "value": 0 } ], "name": "Appointment.status" }, { "optionsetvalues": [ { "label": "label", "value": 0 }, { "label": "label", "value": 0 } ], "name": "Appointment.status" } ], "default_duration": 120, "sellers": [ { "is_current_seller": true, "agency_id": "d497f1ee-6c54-4b01-90e6-d701748f646f", "last_name": "Doe", "id": "abcdf1ee-6c54-4b01-90e6-d701748f", "first_name": "Jane", "is_editable_calendar": true }, { "is_current_seller": true, "agency_id": "d497f1ee-6c54-4b01-90e6-d701748f646f", "last_name": "Doe", "id": "abcdf1ee-6c54-4b01-90e6-d701748f", "first_name": "Jane", "is_editable_calendar": true } ] } }, "MatrixLine": { "type": "object", "properties": { "appointment_type": { "type": "integer", "format": "int32" }, "closing_reason": { "type": "integer", "format": "int32" }, "status": { "type": "integer", "format": "int32" }, "cdv_status": { "type": "integer", "format": "int32" }, "next_appointment_type": { "type": "integer", "format": "int32" } }, "example": { "next_appointment_type": 2, "appointment_type": 6, "cdv_status": 5, "closing_reason": 1, "status": 5 } }, "OptionSet": { "type": "object", "properties": { "name": { "type": "string", "example": "Appointment.status", "description": "field described" }, "optionsetvalues": { "type": "array", "items": { "$ref": "#/components/schemas/OptionSetValue" } } }, "example": { "optionsetvalues": [ { "label": "label", "value": 0 }, { "label": "label", "value": 0 } ], "name": "Appointment.status" } }, "OptionSetValue": { "type": "object", "required": [ "value" ], "properties": { "value": { "type": "integer", "format": "int32", "description": "identifier" }, "label": { "type": "string", "format": "int32", "description": "human readable value" } }, "example": { "label": "label", "value": 0 } }, "Errors": { "type": "object", "properties": { "errors": { "type": "array", "items": { "$ref": "#/components/schemas/Error" } } } }, "Error": { "type": "object", "properties": { "error_short": { "type": "string", "example": "400", "description": "error code" }, "error_comment": { "type": "string", "example": "SQL Error key is not unique", "description": "error details" }, "error_link": { "type": "string", "format": "url", "example": "http://sharepoint/projet/TMA/Doc", "description": "error help link" } } } } }, "tags": [ { "name": "appointments", "description": "Access appointment related information" }, { "name": "recurring appointments", "description": "Access recurring appointment related information" }, { "name": "ref data", "description": "Get referential data" }, { "name": "metadata", "description": "Get metadata" } ] }