code: @POST
      public Response createAgreement(@Context UriInfo uriInfo,  AgreementParam agrementParam) throws NotFoundException, ConflictException, InternalException{
          logger.debug("StartOf createAgreement - Insert /agreements");
          String id, location = null;
          try{
              AgreementHelperE agreementRestHelper = getAgreementHelper();
              id = agreementRestHelper.createAgreement(agrementParam.getAgreement(), agrementParam.getOriginalSerialzedAgreement());
              location = buildResourceLocation(uriInfo.getAbsolutePath().toString() ,id);
              logger.debug("EndOf createAgreement");
          } catch (DBMissingHelperException e) {
              logger.info("createAgreement ConflictException"+ e.getMessage());
              throw new ConflictException(e.getMessage());
          } catch (DBExistsHelperException e) {
              logger.info("createAgreement ConflictException"+ e.getMessage());
              throw new ConflictException(e.getMessage());
          } catch (InternalHelperException e) {
              logger.info("createAgreement InternalException", e);
              throw new InternalException(e.getMessage());
          } catch (ParserHelperException e) {
              logger.info("createAgreement InternalException", e);
              throw new InternalException(e.getMessage());
          }
          logger.debug("EndOf createAgreement");
          return buildResponsePOST(
                  HttpStatus.CREATED,
                  createMessage(HttpStatus.CREATED, id, 
                          "The agreement has been stored successfully in the SLA Repository Database. It has location "+location), location);
      }
docs: Creates a new agreement
  
  
  <pre>
  POST /agreements
  
  Request:
  POST /agreements HTTP/1.1
  Accept: application/xml
  
  Response:
  HTTP/1.1 201 Created
  Content-type: application/xml
  Location: http://.../agreements/$uuid
  
  {@code
  <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  <message code="201" message= "The agreement has been stored successfully in the SLA Repository Database"/>
  }
  
  </pre>
  
  Example:
  <li>curl -H "Content-type: application/xml" -d@agreement02.xml
  localhost:8080/sla-service/agreements -X POST</li>
  
  @return XML information with the different details of the agreement
  @throws NotFoundException
  @throws ConflictException
  @throws InternalException