@Bean
@DependsOn("errorFlow")
public IntegrationFlow flow() {
return IntegrationFlows.from("requestChannel")
.transform(new ObjectToStringTransformer())
.filter((String p) -> p.startsWith("#spring"),
f -> f.discardChannel("rejected"))
.handle(twitterGate())
.transform("payload[0]")
.transform(new ObjectToJsonTransformer())