Last active
March 23, 2017 18:51
-
-
Save karn09/26d93c3649dc4436668d44f5a9314a77 to your computer and use it in GitHub Desktop.
find-by-date.json
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
{ | |
"name": "kustomer.conversation.find-before-date", | |
"app": "kustomer", | |
"type": "internal_api", | |
"inputTemplate": { | |
"method": "POST", | |
"uri": "http://customer_search:8000/v1/customers/search?page=1&pageSize=1", | |
"orgId": "/#_env.orgId", | |
"body": { | |
"queryContext": "conversation", | |
"and": [{ | |
"conversation_updated_at": { | |
"lt": "/#date" | |
} | |
}, { | |
"customer_email": { | |
"equals": "/#customerEmail" | |
} | |
}], | |
"sort": { | |
"conversation_updated_at": { | |
"order": "desc" | |
} | |
} | |
} | |
}, | |
"outputTemplate": { | |
"modifiedBy": "/#body.data.0.relationships.modifiedBy.data.id", | |
"createdBy": "/#body.data.0.relationships.createdBy.data.id", | |
"custom": "/#body.data.0.attributes.custom", | |
"customer": "/#body.data.0.relationships.customer.data.id", | |
"assignedTeams": "/#body.data.0.attributes.assignedTeams", | |
"assignedUsers": "/#body.data.0.attributes.assignedUsers", | |
"lastMessageIn": "/#body.data.0.attributes.lastMessageIn", | |
"sentiment": "/#body.data.0.attributes.sentiment", | |
"suggestedTags": "/#body.data.0.attributes.suggestedTags", | |
"tags": "/#body.data.0.attributes.tags", | |
"modifiedAt": "/#body.data.0.attributes.modifiedAt", | |
"updatedAt": "/#body.data.0.attributes.updatedAt", | |
"createdAt": "/#body.data.0.attributes.createdAt", | |
"satisfaction": "/#body.data.0.attributes.satisfaction", | |
"noteCount": "/#body.data.0.attributes.noteCount", | |
"messageCount": "/#body.data.0.attributes.messageCount", | |
"snooze": "/#body.data.0.attributes.snooze", | |
"status": "/#body.data.0.attributes.status", | |
"channels": "/#body.data.0.attributes.channels", | |
"preview": "/#body.data.0.attributes.preview", | |
"name": "/#body.data.0.attributes.name", | |
"id": "/#body.data.0.id" | |
}, | |
"inputSchema": { | |
"additionalProperties": false, | |
"required": [ | |
"customerEmail", "date" | |
], | |
"properties": { | |
"customerEmail": { | |
"type": "string" | |
}, | |
"date": { | |
"type": "string" | |
} | |
}, | |
"type": "object" | |
}, | |
"outputSchema": { | |
"definitions": { | |
"team": { | |
"type": "string" | |
} | |
}, | |
"properties": { | |
"custom": { | |
"type": "object" | |
}, | |
"modifiedBy": { | |
"type": "string" | |
}, | |
"createdBy": { | |
"type": "string" | |
}, | |
"customer": { | |
"type": "string" | |
}, | |
"assignedTeams": { | |
"items": { | |
"type": "string" | |
}, | |
"type": "array" | |
}, | |
"assignedUsers": { | |
"items": { | |
"type": "string" | |
}, | |
"type": "array" | |
}, | |
"lastMessageIn": { | |
"type": "object" | |
}, | |
"sentiment": { | |
"type": "object" | |
}, | |
"suggestedTags": { | |
"items": { | |
"type": "object" | |
}, | |
"type": "array" | |
}, | |
"tags": { | |
"items": { | |
"type": "string" | |
}, | |
"type": "array" | |
}, | |
"modifiedAt": { | |
"type": "string" | |
}, | |
"updatedAt": { | |
"type": "string" | |
}, | |
"createdAt": { | |
"type": "string" | |
}, | |
"satisfaction": { | |
"type": "number" | |
}, | |
"noteCount": { | |
"type": "number" | |
}, | |
"messageCount": { | |
"type": "number" | |
}, | |
"snooze": { | |
"type": "object" | |
}, | |
"status": { | |
"type": "string" | |
}, | |
"channels": { | |
"items": { | |
"type": "string" | |
}, | |
"type": "array" | |
}, | |
"preview": { | |
"type": "string" | |
}, | |
"name": { | |
"type": "string" | |
}, | |
"id": { | |
"type": "string" | |
} | |
}, | |
"type": "object" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment