Skip to content

Instantly share code, notes, and snippets.

View mamund's full-sized avatar

Mike Amundsen mamund

View GitHub Profile
@mamund
mamund / book-store.xml
Created August 4, 2023 15:29
Bookstore for XMLPath
<?xml version="1.0" encoding="UTF-8" ?>
<store>
<book>
<category>reference</category>
<author>Nigel Rees</author>
<title>Sayings of the Century</title>
<price>8.95</price>
</book>
<book>
<category>fiction</category>
@mamund
mamund / book-store.json
Created August 4, 2023 15:27
Bookstore data for JSONPATH
{ "store": {
"book": [
{ "category": "reference",
"author": "Nigel Rees",
"title": "Sayings of the Century",
"price": 8.95
},
{ "category": "fiction",
"author": "Evelyn Waugh",
"title": "Sword of Honour",
@mamund
mamund / code-interfaces.js
Last active July 21, 2022 00:28
prototype for a composable service
var jobInterface(args) {
function init(args) {}
function stateRead(args) {}
function stateWrite(args) {}
function JobStart(args) {}
function JobCancel(args) {}
function JobRestart(args) {}
function JobRevert(args) {}
}
@mamund
mamund / CWAD-46-README-Mocking-Bookstore-API.md
Created March 3, 2022 01:12
CWAD-46-README-Mocking-Bookstore-API

Bookstore README Mocking

Simple README Mock for the Bookstore API

listBooks()

*** REQUEST ***
GET /books
Accept: application/json
@mamund
mamund / bookstore-mock.md
Last active March 3, 2022 00:36
README Mocking

Bookstore README Mocking

listBooks()

*** REQUEST ***
GET /books
Accept: application/json

*** RESPONSE ***
200 OK

Shopping API Modeled Resources

Book

Property Name Description
title The book title
isbn The unique ISBN of the book
authors List of Book Author resources

Shopping API

  • Supports the book browsing experience and cart management
  • Scope: Public

Add Operations

Place these operations on the proper lines in the table below.

  • viewCart()
  • clearCart()

Shopping API

  • Supports the book browsing experience and cart management
  • Scope: Public

Add Resources

Place the resource(s) on the proper line in the table below

  • Book (two lines)
  • CartItem, Cart (two lines)

Shopping API

  • Supports the book browsing experience and cart management
  • Scope: Public

Add Events

Place the events on the proper line in the table

  • Cart.ItemAdded
  • Cart.ItemRemoved

Shopping API

  • Supports the book browsing experience and cart management
  • Scope: Public

Add Read/Write Traits

Place the read/write traits on the proper lines in the table below.

  • read (three lines)
  • write (three lines)