Skip to main content

Timeline

There is a timeline API made for an order or customer. By using this api, many operations can be done on the order and customer side. For example, you can view the shipping status information of an order on the timeline. You can edit these messages yourself or add different messages. Likewise, a user can add messages to their customers' timeline as they wish, on the screen they view.

Overview

By using this api, you can add message to timeline. You can write this message format using the string or in md format. While writing the message, you can link other users and add the product or customer as a reference.

Input

Timeline

You can see the required fields for the message you want to add to the timeline in the input.

type TimelineInput {
message: String!
sourceId: String!
sourceType: SourceTypeEnum!
}

Fields

messageString!required

The message you want to add

sourceIdString!required

Indicates which source the message added to the timeline belongs to. For example, if a message is added to the timeline for an order, sourceId is the id of the order. The same is true for the customer.

sourceTypeSourceTypeEnum!required

The message source type you want to add.

Mutations

Add Custom Timeline Entry

addCustomTimelineEntry(
input: TimelineInput!
): Boolean!

Arguments

inputTimelineInput!required

Return Type

BooleanBoolean

The Boolean scalar type represents true or false.

Examples

Add a custom timeline entry

curl --location --request POST 'https://api.myikas.com/api/v1/admin/graphql' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <your_access_token>' \
--data-raw '{"query":"mutation { addCustomTimelineEntry( input: { message: \"deneme\" sourceId: \"44265c6d-6d58-4e29-9544-1f6305df9bf9\" sourceType: CUSTOMER } ) }"}'

Response

{
"data": {
"addCustomTimelineEntry": true
}
}