diff --git a/main/pom.xml b/main/pom.xml
index 19c54db..1a1f537 100644
--- a/main/pom.xml
+++ b/main/pom.xml
@@ -68,6 +68,22 @@
             <version>1.18.4</version>
             <scope>provided</scope>
         </dependency>
+        <dependency>
+            <groupId>org.onap.policy.common</groupId>
+            <artifactId>utils-test</artifactId>
+            <version>${policy.common.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-mockito</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.assertj</groupId>
+            <artifactId>assertj-core</artifactId>
+            <scope>test</scope>
+        </dependency>
     </dependencies>
 
     <build>
diff --git a/main/src/main/java/org/onap/policy/pap/main/comm/PdpClient.java b/main/src/main/java/org/onap/policy/pap/main/comm/PdpClient.java
new file mode 100644
index 0000000..7919912
--- /dev/null
+++ b/main/src/main/java/org/onap/policy/pap/main/comm/PdpClient.java
@@ -0,0 +1,101 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP PAP
+ * ================================================================================
+ * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.policy.pap.main.comm;
+
+import java.util.List;
+import lombok.Getter;
+import org.onap.policy.common.endpoints.event.comm.TopicEndpoint;
+import org.onap.policy.common.endpoints.event.comm.TopicSink;
+import org.onap.policy.common.utils.coder.Coder;
+import org.onap.policy.common.utils.coder.CoderException;
+import org.onap.policy.common.utils.coder.StandardCoder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Client for communication with PDPs.
+ */
+public class PdpClient {
+    private static final Logger logger = LoggerFactory.getLogger(PdpClient.class);
+
+    /**
+     * Coder used to encode messages being sent to PDPs.
+     */
+    private static final Coder CODER = new StandardCoder();
+
+    /**
+     * Topic to which messages are published.
+     */
+    @Getter
+    private final String topic;
+
+    /**
+     * Where messages are published.
+     */
+    private final TopicSink sink;
+
+    /**
+     * Constructs the object.
+     *
+     * @param topic topic to which messages should be published
+     * @throws PdpClientException if the topic does not exist
+     */
+    public PdpClient(String topic) throws PdpClientException {
+        this.topic = topic;
+
+        List<TopicSink> lst = getTopicSinks(topic);
+        if (lst.isEmpty()) {
+            throw new PdpClientException("no sinks for topic: " + topic);
+        }
+
+        this.sink = lst.get(0);
+    }
+
+    /**
+     * Sends a message to the PDPs via the topic, after encoding the message as json.
+     *
+     * @param message message to be encoded and sent
+     * @return {@code true} if the message was successfully sent/enqueued, {@code false}
+     *         otherwise
+     */
+    public boolean send(Object message) {
+        try {
+            String json = CODER.encode(message);
+            return sink.send(json);
+
+        } catch (RuntimeException | CoderException e) {
+            logger.warn("send to {} failed because of {}", topic, e.getMessage(), e);
+            return false;
+        }
+    }
+
+    // the remaining methods are wrappers that can be overridden by junit tests
+
+    /**
+     * Gets the sinks for a given topic.
+     *
+     * @param topic the topic of interest
+     * @return the sinks for the topic
+     */
+    protected List<TopicSink> getTopicSinks(String topic) {
+        return TopicEndpoint.manager.getTopicSinks(topic);
+    }
+}
diff --git a/main/src/main/java/org/onap/policy/pap/main/comm/PdpClientException.java b/main/src/main/java/org/onap/policy/pap/main/comm/PdpClientException.java
new file mode 100644
index 0000000..547812f
--- /dev/null
+++ b/main/src/main/java/org/onap/policy/pap/main/comm/PdpClientException.java
@@ -0,0 +1,49 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP PAP
+ * ================================================================================
+ * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.policy.pap.main.comm;
+
+/**
+ * Exception thrown by PDP client classes.
+ */
+public class PdpClientException extends Exception {
+    private static final long serialVersionUID = 1L;
+
+    public PdpClientException() {
+        super();
+    }
+
+    public PdpClientException(String message) {
+        super(message);
+    }
+
+    public PdpClientException(Throwable cause) {
+        super(cause);
+    }
+
+    public PdpClientException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+    public PdpClientException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
+        super(message, cause, enableSuppression, writableStackTrace);
+    }
+
+}
diff --git a/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientExceptionTest.java b/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientExceptionTest.java
new file mode 100644
index 0000000..dcaba78
--- /dev/null
+++ b/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientExceptionTest.java
@@ -0,0 +1,34 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP PAP
+ * ================================================================================
+ * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.policy.pap.main.comm;
+
+import static org.junit.Assert.assertEquals;
+
+import org.junit.Test;
+import org.onap.policy.common.utils.test.ExceptionsTester;
+
+public class PdpClientExceptionTest {
+
+    @Test
+    public void test() {
+        assertEquals(5, new ExceptionsTester().test(PdpClientException.class));
+    }
+}
diff --git a/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientTest.java b/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientTest.java
new file mode 100644
index 0000000..22823bf
--- /dev/null
+++ b/main/src/test/java/org/onap/policy/pap/main/comm/PdpClientTest.java
@@ -0,0 +1,141 @@
+/*
+ * ============LICENSE_START=======================================================
+ * ONAP PAP
+ * ================================================================================
+ * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.policy.pap.main.comm;
+
+import static org.assertj.core.api.Assertions.assertThatThrownBy;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertSame;
+import static org.mockito.Matchers.anyString;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.verify;
+import static org.mockito.Mockito.when;
+
+import java.util.Arrays;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Properties;
+import java.util.concurrent.atomic.AtomicReference;
+import org.junit.Before;
+import org.junit.Test;
+import org.mockito.internal.util.reflection.Whitebox;
+import org.onap.policy.common.endpoints.event.comm.Topic.CommInfrastructure;
+import org.onap.policy.common.endpoints.event.comm.TopicEndpoint;
+import org.onap.policy.common.endpoints.event.comm.TopicListener;
+import org.onap.policy.common.endpoints.event.comm.TopicSink;
+
+public class PdpClientTest {
+    private static final String SINK_FIELD_NAME = "sink";
+    private static final String TOPIC = "my-topic";
+
+    private PdpClient client;
+    private TopicSink sink;
+    private List<TopicSink> sinks;
+
+    /**
+     * Creates mocks and an initial client object.
+     *
+     * @throws Exception if an error occurs
+     */
+    @Before
+    public void setUp() throws Exception {
+        sink = mock(TopicSink.class);
+        when(sink.send(anyString())).thenReturn(true);
+
+        sinks = Arrays.asList(sink, null);
+
+        client = new PdpClient2(TOPIC);
+    }
+
+    /**
+     * Uses a real NO-OP topic sink.
+     */
+    @Test
+    public void testGetTopicSinks() throws Exception {
+        // clear all topics and then configure one topic
+        TopicEndpoint.manager.shutdown();
+
+        Properties props = new Properties();
+        props.setProperty("noop.sink.topics", TOPIC);
+        TopicEndpoint.manager.addTopicSinks(props);
+
+        sink = TopicEndpoint.manager.getNoopTopicSink(TOPIC);
+        assertNotNull(sink);
+
+        AtomicReference<String> evref = new AtomicReference<>(null);
+
+        sink.register(new TopicListener() {
+            @Override
+            public void onTopicEvent(CommInfrastructure infra, String topic, String event) {
+                evref.set(event);
+            }
+        });
+
+        sink.start();
+
+        client = new PdpClient(TOPIC);
+        client.send(100);
+
+        assertEquals("100", evref.get());
+    }
+
+    @Test
+    public void testPdpClient_testGetTopic() {
+        assertEquals(TOPIC, client.getTopic());
+        assertSame(sink, Whitebox.getInternalState(client, SINK_FIELD_NAME));
+
+        // unknown topic -> should throw exception
+        sinks = new LinkedList<>();
+        assertThatThrownBy(() -> new PdpClient2(TOPIC)).isInstanceOf(PdpClientException.class)
+                        .hasMessage("no sinks for topic: my-topic");
+    }
+
+    @Test
+    public void testSend() throws Exception {
+        client.send(Arrays.asList("abc", "def"));
+        verify(sink).send("['abc','def']".replace('\'', '"'));
+
+        // sink send fails
+        when(sink.send(anyString())).thenReturn(false);
+        assertFalse(client.send("ghi"));
+
+        // sink send throws an exception
+        RuntimeException ex = new RuntimeException("expected exception");
+        when(sink.send(anyString())).thenThrow(ex);
+        assertFalse(client.send("jkl"));
+    }
+
+    /**
+     * PdpClient with some overrides.
+     */
+    private class PdpClient2 extends PdpClient {
+
+        public PdpClient2(String topic) throws PdpClientException {
+            super(topic);
+        }
+
+        @Override
+        protected List<TopicSink> getTopicSinks(String topic) {
+            return sinks;
+        }
+    }
+}
diff --git a/pom.xml b/pom.xml
index a1d3378..91f9f85 100644
--- a/pom.xml
+++ b/pom.xml
@@ -26,7 +26,7 @@
     <parent>
         <groupId>org.onap.policy.parent</groupId>
         <artifactId>integration</artifactId>
-        <version>2.0.0</version>
+        <version>2.1.0-SNAPSHOT</version>
         <relativePath />
     </parent>
 
