package io.oilfox.backend.api.controllers;


import io.oilfox.backend.api.http.AbstractController;
import io.oilfox.backend.api.shared.annotations.*;

import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Response;


/**
 * Created by ipusic on 1/22/16.
 */
@ApiDocController
public class PublicController extends AbstractController{



    @Produces("text/plain")
    @ApiDocDescription("Returns Pong")
    public Response getPing() {
        return Response.ok("Pong").status(200).build();
    }

    @Authenticated
    @Produces("application/json")
    @ApiDocDescription("Returns facebook id")
    public Response getFacebookId(@PathParam("id") String id) throws Exception {


        String message = "{\"text\":\"your Facebook ID is "+id+"\"}";


        return json(message);
    }
}

@@ -729,16 +729,17 @@
 sage = %22
+%5B
 %7B%5C%22text%5C
@@ -771,16 +771,17 @@
 +id+%22%5C%22%7D
+%5D
 %22;%0A%0A%0A   

fix message format