Page MenuHomePhabricator

Expose conduit API methods for Phurl URLs
ClosedPublic

Authored by jcox on Sep 27 2016, 2:34 PM.
Tags
None
Referenced Files
F13048134: D16600.diff
Thu, Apr 18, 4:42 PM
Unknown Object (File)
Mar 17 2024, 5:43 PM
Unknown Object (File)
Mar 9 2024, 10:34 PM
Unknown Object (File)
Feb 16 2024, 9:20 AM
Unknown Object (File)
Feb 12 2024, 10:55 AM
Unknown Object (File)
Feb 8 2024, 7:34 PM
Unknown Object (File)
Feb 8 2024, 7:52 AM
Unknown Object (File)
Feb 3 2024, 12:05 PM

Details

Summary

Fixes T10681. Adds a search API endpoint and an edit API endpoint for Phurl URLs. I still need to add the ability to search by name, alias, URL, and maybe description.

Test Plan

Test the methods through /conduit/method/phurls.search/ and /conduit/method/phurls.edit/

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jcox retitled this revision from to Expose conduit API methods for Phurl URLs.
jcox updated this object.
jcox edited the test plan for this revision. (Show Details)
jcox edited edge metadata.
epriestley added a reviewer: epriestley.
epriestley added inline comments.
src/applications/phurl/conduit/PhabricatorPhurlURLEditConduitAPIMethod.php
17

By convention, prefer capitalizing application names ("Phurl").

src/applications/phurl/storage/PhabricatorPhurlURL.php
236

We don't actually return the short URL anywhere, but it seems possibly useful? Maybe:

'urls' => array(
  'long' => $this->getLongURL(),
  'short' => $this->getRedirectURI(),
),

Although you'll need to fiddle with getRedirectURI() to make sure it always has a protocol/domain, since it currently won't if phurl.short-uri is unconfigured.

This revision is now accepted and ready to land.Sep 27 2016, 3:45 PM
jcox edited edge metadata.

Added ability to search by URL name substring

(That ngrams stuff looks right to me, too.)

Added short URL to results

Make getRedirectURI always have a domain

This revision was automatically updated to reflect the committed changes.