Quantcast
Channel: Spring Community Forums - Social
Viewing all articles
Browse latest Browse all 145

correct way to use a provider template in controller/service

$
0
0
I have successfully connected via connect controller to service provider. In another controller I want to access the API. Can i inject the ProviderTemplate class and use it? What is the proper way to now consume this API? I have been digging through the docs but its not clear to me.

so for example in my service I want to:

@Autorwired:
private FacebookTemplate fbTemplate;

@RequestMethod(value={},RequestMethod.GET){
public String doSomethingWithAPI(){
return fbTemplate.likeOperations.doSomething;
}
}
Thanks,
Barry

Viewing all articles
Browse latest Browse all 145

Trending Articles