Skip to content

Free, Open Source, Self-Hosted WhatsApp API Gateway

docs(sdk): mark Python contact block and unblock as OPERATOR

Yudhi Armyndharis7d176054a039
diff --git a/sdk/python/openwa/resources/contacts.py b/sdk/python/openwa/resources/contacts.py
index 5cd4a8331..0b16ed362 100644
--- a/sdk/python/openwa/resources/contacts.py
+++ b/sdk/python/openwa/resources/contacts.py
@@ -57,6 +57,7 @@ class ContactsResource:
return self._http.request("GET", f"/api/sessions/{quote_segment(session_id)}/contacts/{quote_segment(contact_id)}/phone")
def block(self, session_id: str, contact_id: str) -> SuccessResult:
+ """Block a contact (OPERATOR)."""
return self._http.request("POST", f"/api/sessions/{quote_segment(session_id)}/contacts/{quote_segment(contact_id)}/block")
def upsert(self, session_id: str, contact_id: str, body: UpsertContactRequest) -> SuccessResult:
@@ -72,6 +73,7 @@ class ContactsResource:
)
def unblock(self, session_id: str, contact_id: str) -> SuccessResult:
+ """Unblock a contact (OPERATOR)."""
return self._http.request("DELETE", f"/api/sessions/{quote_segment(session_id)}/contacts/{quote_segment(contact_id)}/block")
def list_blocked(self, session_id: str) -> List[str]: