Skip to content

Instantly share code, notes, and snippets.

@crh
Created October 25, 2012 10:40
Show Gist options
  • Save crh/3951915 to your computer and use it in GitHub Desktop.
Save crh/3951915 to your computer and use it in GitHub Desktop.
Discussion Material for desigining URI in DDB Front End

On URI Design for DDB Help Desk

Github Search URI

what the user wants:

she wants to search for *repositories* using *keyword* mustache that use JavaScript as *language*

Le URI:

https://github.com/search?q=mustache&repo=&langOverride=&start_value=1&type=Repositories&language=JavaScript

relevant parameters

  • ?q={alphanumeric characters} keyword query

    • ?start_value={1 | 2 | 3| ...}

      • for paging
    • ?type={Users | Repositories| Code | Everything}

      • type of search, i.e. users, repositories
      • is finite
    • ?language={JavaScript, Java, HTML, ...}

      • is finite.

recomendation for DDB Help Desk Web App URI

  1. alternative

using resources as path.

example:

  • //example.org/helpdesk/users?username=crh
  • //example.org/helpdesk/organizations?status=withold&q=fiz
  1. alternative
  • path ::= search
  • query parameters
    • type :: = {users, organizations, all}
    • status ::= {withold}

example:

  • //example.org/helpdesk/search?type=users&username=crh
  • //example.org/helpdesk/search?type=all&q=karlsruhe
  • //example.org/helpdesk/search?type=organization&status=withold&q=fiz

Notes

  • / path, usually hierarchical data[3]
  • '?' query, non-hierarchical data
  • # (a number sign)/ fragment

Reading List:

  1. Intelligent State Handling

Overiview of State management in Ajax-y Web App.

  1. Naming and Adressing: URIs, URLs,... Overview of addressability in Web

  2. URI: Generic Syntax Le URI standard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment