forked from Rio517/slate
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
publish: REST API: Add partnerships parameter to petition update endp…
- Loading branch information
1 parent
89690b0
commit 864066f
Showing
2 changed files
with
48 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -471,6 +471,9 @@ | |
<li> | ||
<a href="#webhook-endpoints-petition-inappropriate-creator_message" class="toc-h2 toc-link" data-title="petition.inappropriate.creator_message">petition.inappropriate.creator_message</a> | ||
</li> | ||
<li> | ||
<a href="#webhook-endpoints-petition-member_email_reply_received" class="toc-h2 toc-link" data-title="petition.member_email_reply_received">petition.member_email_reply_received</a> | ||
</li> | ||
<li> | ||
<a href="#webhook-endpoints-petition-mentor_assigned" class="toc-h2 toc-link" data-title="petition.mentor_assigned">petition.mentor_assigned</a> | ||
</li> | ||
|
@@ -2744,6 +2747,10 @@ <h2 id='webhook-endpoints-webhook-types-summary'>Webhook types summary</h2> | |
<td>An inappropriate petition's creator writes a message to admins</td> | ||
</tr> | ||
<tr> | ||
<td><a href="#webhook-endpoints-petition-member_email_reply_received">petition.member_email_reply_received</a></td> | ||
<td>A member replied to a petition email</td> | ||
</tr> | ||
<tr> | ||
<td><a href="#webhook-endpoints-petition-mentor_assigned">petition.mentor_assigned</a></td> | ||
<td>Mentor was assigned to the petition</td> | ||
</tr> | ||
|
@@ -3028,6 +3035,7 @@ <h2 id='webhook-endpoints-event-created'>event.created</h2> | |
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2021-07-23T19:09:41Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"location_venue"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Queens Public Library at McGoldrick"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"unconfirmed_location"</span><span class="p">:</span><span class="w"> </span><span class="kc">false</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"host"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">180</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"email"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
|
@@ -3120,6 +3128,7 @@ <h2 id='webhook-endpoints-event-created-requires_moderation'>event.created.requi | |
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2021-07-23T19:09:41Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"location_venue"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Queens Public Library at McGoldrick"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"unconfirmed_location"</span><span class="p">:</span><span class="w"> </span><span class="kc">false</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"host"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">180</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"email"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
|
@@ -3242,6 +3251,7 @@ <h2 id='webhook-endpoints-event-mentor_assigned'>event.mentor_assigned</h2> | |
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2021-07-23T19:09:41Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"location_venue"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Queens Public Library at McGoldrick"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"unconfirmed_location"</span><span class="p">:</span><span class="w"> </span><span class="kc">false</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"host"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">180</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"email"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
|
@@ -3334,6 +3344,7 @@ <h2 id='webhook-endpoints-event-mentor_removed'>event.mentor_removed</h2> | |
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2021-07-23T19:09:41Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"location_venue"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Queens Public Library at McGoldrick"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"unconfirmed_location"</span><span class="p">:</span><span class="w"> </span><span class="kc">false</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"host"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">180</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"email"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
|
@@ -3423,6 +3434,7 @@ <h2 id='webhook-endpoints-event-updated'>event.updated</h2> | |
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2021-07-23T19:09:41Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"location_venue"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Queens Public Library at McGoldrick"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"unconfirmed_location"</span><span class="p">:</span><span class="w"> </span><span class="kc">false</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"host"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">180</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"email"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
|
@@ -4419,6 +4431,36 @@ <h2 id='webhook-endpoints-petition-inappropriate-creator_message'>petition.inapp | |
</span><span class="p">}</span><span class="w"> | ||
</span></code></pre></div> | ||
<p>An inappropriate petition's creator writes a message to admins</p> | ||
<h2 id='webhook-endpoints-petition-member_email_reply_received'>petition.member_email_reply_received</h2> | ||
<blockquote> | ||
<p>Example payload for <code>petition.member_email_reply_received</code>:</p> | ||
</blockquote> | ||
<div class="highlight"><pre class="highlight json tab-json"><code><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"type"</span><span class="p">:</span><span class="w"> </span><span class="s2">"petition.member_email_reply_received"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"data"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"id"</span><span class="p">:</span><span class="w"> </span><span class="mi">359</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"campaign_type"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Event"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"campaign_id"</span><span class="p">:</span><span class="w"> </span><span class="mi">8268</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"replied_email_type"</span><span class="p">:</span><span class="w"> </span><span class="s2">"blast_email"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"status"</span><span class="p">:</span><span class="w"> </span><span class="s2">"verified_pending_delivery"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"from"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Jane Doe <[email protected]>"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"to"</span><span class="p">:</span><span class="w"> </span><span class="s2">"[email protected]"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"subject"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Re: We made it!"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"body_plain"</span><span class="p">:</span><span class="w"> </span><span class="s2">"Hi Jane, I'm so glad we made it! I can't wait to see you at the event. Best, John"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"body_html"</span><span class="p">:</span><span class="w"> </span><span class="s2">"<p>Hi Jane, I'm so glad we made it! I can't wait to see you at the event.</p><p>Best, John</p>"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"headers"</span><span class="p">:</span><span class="w"> </span><span class="p">{</span><span class="w"> | ||
</span><span class="nl">"Message-ID"</span><span class="p">:</span><span class="w"> </span><span class="s2">"<abcde-098765>"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"blast_email_id"</span><span class="p">:</span><span class="w"> </span><span class="mi">87</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"member_id"</span><span class="p">:</span><span class="w"> </span><span class="mi">1234</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"reject_reasons"</span><span class="p">:</span><span class="w"> </span><span class="kc">null</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"created_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2024-09-12T15:00:00Z"</span><span class="p">,</span><span class="w"> | ||
</span><span class="nl">"updated_at"</span><span class="p">:</span><span class="w"> </span><span class="s2">"2024-09-12T16:30:00Z"</span><span class="w"> | ||
</span><span class="p">},</span><span class="w"> | ||
</span><span class="nl">"jid"</span><span class="p">:</span><span class="w"> </span><span class="s2">"030ee43a4fa9788e084d9cfc"</span><span class="w"> | ||
</span><span class="p">}</span><span class="w"> | ||
</span></code></pre></div> | ||
<p>A member replied to a petition email</p> | ||
<h2 id='webhook-endpoints-petition-mentor_assigned'>petition.mentor_assigned</h2> | ||
<blockquote> | ||
<p>Example payload for <code>petition.mentor_assigned</code>:</p> | ||
|
@@ -7423,6 +7465,11 @@ <h3 id='authenticated-rest-api-petitions-update'>Update</h3> | |
<td>Turn off the form that allows people to sign the petition via the petition page</td> | ||
</tr> | ||
<tr> | ||
<td>partnerships</td> | ||
<td>Array</td> | ||
<td>List of partnerships this petition should be associated with, formatted like <code>[{"slug": "foo"}, {"slug": "bar"}]</code>. If the petition was associated with any partnerships that are not included in the list, it will be removed from those partnerships.</td> | ||
</tr> | ||
<tr> | ||
<td>petition_creator_name_override</td> | ||
<td>String</td> | ||
<td>Name to display for the petition creator on the petition page. Set to <code>null</code> to use the name from the petition creator's user account.</td> | ||
|