Cards


Search

Search for cards.

Endpoint

Method URI Description
GET /users/{user_id}/post_cards Search user owned cards

Example Response

{
    "data": [
        {
            "id": 1,
            "provider": "Handwrytten",
            "card_id": "72",
            "font_id": "hwChase",
            "font_name": "Charming Chase",
            "sender_name": "Gus Grasshopper",
            "sender_company": "Happy Grasshopper",
            "sender_address_id": 1,
            "name": "Message name..",
            "description": null,
            "greeting_with_first_name": "Hello { {c.first_name} },",
            "greeting_without_first_name": "Hello,",
            "body": "French is an awesome language, isn't it?",
            "status": "Sent",
            "reason": null,
            "send_type": "Asap",
            "send_at": "2019-10-17T02:53:00Z",
            "sending_at": "2019-10-17T02:54:09Z",
            "sent_at": "2019-10-17T02:54:15Z",
            "recipients": [],
            "reporting": {
                "date": null,
                "sent": 1,
                "processed": 0,
                "delivered": 0,
                "open": 0,
                "click": 0,
                "reply": 0,
                "spamreport": 0,
                "unsubscribe": 0,
                "deferred": 0,
                "dropped": 0,
                "bounce": 0,
                "hard_bounce": 0,
                "soft_bounce": 0,
                "failed": 0
            },
            "created_at": "2019-10-17T02:53:02Z",
            "updated_at": "2019-10-17T02:54:15Z",
            "deleted_at": null
        }
    ],
    "links": {
        "first": "http://api.happygrasshopper.com/v3/users/77179/post_cards?page=1",
        "last": "http://api.happygrasshopper.com/v3/users/77179/post_cards?page=1",
        "prev": null,
        "next": null
    },
    "meta": {
        "current_page": 1,
        "from": 1,
        "last_page": 1,
        "path": "http://api.happygrasshopper.com/v3/users/77179/post_cards",
        "per_page": 15,
        "to": 4,
        "total": 4
    }
}

Create

Create a card.

Endpoint

Method URI Description
POST /users/{user_id}/post_cards Create a user owne card

Body Params

{
    "provider": "Handwrytten",
    "card_id": "72",
    "font_id": "hwChase",
    "font_name": "Charming Chase",
    "sender_name": "Gus Grasshopper",
    "sender_company": "Happy Grasshopper",
    "sender_address_id": 1,
    "name": "Message name..",
    "description": null,
    "greeting_with_first_name": "Hello { {c.first_name} },",
    "greeting_without_first_name": "Hello,",
    "body": "French is an awesome language, isn't it?",
    "status": "Sent",
    "send_type": "Asap",
    "send_at": "2019-10-17T02:53:00Z",
    "recipients": []
}

Example Response

{
    "id": 1,
    "provider": "Handwrytten",
    "card_id": "72",
    "font_id": "hwChase",
    "font_name": "Charming Chase",
    "sender_name": "Gus Grasshopper",
    "sender_company": "Happy Grasshopper",
    "sender_address_id": 1,
    "name": "Message name..",
    "description": null,
    "greeting_with_first_name": "Hello { {c.first_name} },",
    "greeting_without_first_name": "Hello,",
    "body": "French is an awesome language, isn't it?",
    "status": "Sent",
    "reason": null,
    "send_type": "Asap",
    "send_at": "2019-10-17T02:53:00Z",
    "sending_at": null,
    "sent_at": null,
    "recipients": [],
    "reporting": {
        "date": null,
        "sent": 1,
        "processed": 0,
        "delivered": 0,
        "open": 0,
        "click": 0,
        "reply": 0,
        "spamreport": 0,
        "unsubscribe": 0,
        "deferred": 0,
        "dropped": 0,
        "bounce": 0,
        "hard_bounce": 0,
        "soft_bounce": 0,
        "failed": 0
    },
    "created_at": "2019-10-17T02:53:02Z",
    "updated_at": "2019-10-17T02:54:15Z",
    "deleted_at": null
}

Read

Retrieve a card.

Endpoint

Method URI Description
GET /post_cards/{post_card_id} Retrieve a card by it's id

Example Response

{
    "id": 1,
    "provider": "Handwrytten",
    "card_id": "72",
    "font_id": "hwChase",
    "font_name": "Charming Chase",
    "sender_name": "Gus Grasshopper",
    "sender_company": "Happy Grasshopper",
    "sender_address_id": 1,
    "name": "Message name..",
    "description": null,
    "greeting_with_first_name": "Hello { {c.first_name} },",
    "greeting_without_first_name": "Hello,",
    "body": "French is an awesome language, isn't it?",
    "status": "Sent",
    "reason": null,
    "send_type": "Asap",
    "send_at": "2019-10-17T02:53:00Z",
    "sending_at": "2019-10-17T02:54:09Z",
    "sent_at": "2019-10-17T02:54:15Z",
    "recipients": [],
    "reporting": {
        "date": null,
        "sent": 1,
        "processed": 0,
        "delivered": 0,
        "open": 0,
        "click": 0,
        "reply": 0,
        "spamreport": 0,
        "unsubscribe": 0,
        "deferred": 0,
        "dropped": 0,
        "bounce": 0,
        "hard_bounce": 0,
        "soft_bounce": 0,
        "failed": 0
    },
    "created_at": "2019-10-17T02:53:02Z",
    "updated_at": "2019-10-17T02:54:15Z",
    "deleted_at": null
}

Update

Update a card.

Endpoint

Method URI Description
PUT /post_cards/{post_card_id} Update a card

Body Params

{
    "provider": "Handwrytten",
    "card_id": "72",
    "font_id": "hwChase",
    "font_name": "Charming Chase",
    "sender_name": "Gus Grasshopper",
    "sender_company": "Happy Grasshopper",
    "sender_address_id": 1,
    "name": "Message name..",
    "description": null,
    "greeting_with_first_name": "Hello { {c.first_name} },",
    "greeting_without_first_name": "Hello,",
    "body": "French is an awesome language, isn't it?",
    "status": "Sent",
    "send_type": "Asap",
    "send_at": "2019-10-17T02:53:00Z",
    "recipients": []
}

Example Response

{
    "id": 1,
    "provider": "Handwrytten",
    "card_id": "72",
    "font_id": "hwChase",
    "font_name": "Charming Chase",
    "sender_name": "Gus Grasshopper",
    "sender_company": "Happy Grasshopper",
    "sender_address_id": 1,
    "name": "Message name..",
    "description": null,
    "greeting_with_first_name": "Hello { {c.first_name} },",
    "greeting_without_first_name": "Hello,",
    "body": "French is an awesome language, isn't it?",
    "status": "Sent",
    "reason": null,
    "send_type": "Asap",
    "send_at": "2019-10-17T02:53:00Z",
    "sending_at": "2019-10-17T02:54:09Z",
    "sent_at": "2019-10-17T02:54:15Z",
    "recipients": [],
    "reporting": {
        "date": null,
        "sent": 1,
        "processed": 0,
        "delivered": 0,
        "open": 0,
        "click": 0,
        "reply": 0,
        "spamreport": 0,
        "unsubscribe": 0,
        "deferred": 0,
        "dropped": 0,
        "bounce": 0,
        "hard_bounce": 0,
        "soft_bounce": 0,
        "failed": 0
    },
    "created_at": "2019-10-17T02:53:02Z",
    "updated_at": "2019-10-17T02:54:15Z",
    "deleted_at": null
}

Delete

Delete a card.

Endpoint

Method URI Description
DELETE /post_cards/{post_card_id} Delete a card by it's id

Example Response

{
    "success": true
}