Get a single dupe detect rule

Content

Resource URL

https://apps.ticketmatic.com/api/1/{accountname}/settings/system/dupedetectrules/{id}

Example

Request

1use Ticketmatic\Endpoints\Settings\System\Dupedetectrules;
2
3$result = Dupedetectrules::get($client, $id);

Response

 1object(\Ticketmatic\Model\DupeDetectRule) (5) {
 2  ["id"]=>
 3  int(0)
 4  ["name"]=>
 5  string(4) "name"
 6  ["criteria"]=>
 7  array(1) {
 8    [0]=>
 9    object(\Ticketmatic\Model\DupeDetectCriteria) (2) {
10      ["field"]=>
11      string(5) "email"
12      ["matcher"]=>
13      string(5) "exact"
14    }
15  }
16  ["createdts"]=>
17  object(\DateTime) (3) {
18    ["date"]=>
19    string(26) "2014-09-26 15:24:36.000000"
20    ["timezone_type"]=>
21    int(3)
22    ["timezone"]=>
23    string(3) "UTC"
24  }
25  ["lastupdatets"]=>
26  object(\DateTime) (3) {
27    ["date"]=>
28    string(26) "2014-09-26 15:24:36.000000"
29    ["timezone_type"]=>
30    int(3)
31    ["timezone"]=>
32    string(3) "UTC"
33  }
34}
35

Request

1import (
2    "github.com/ticketmatic/tm-go/ticketmatic"
3    "github.com/ticketmatic/tm-go/ticketmatic/settings/system/dupedetectrules"
4)
5
6result, err := dupedetectrules.Get(client, id)

Response

 1result := &ticketmatic.DupeDetectRule{
 2    Id: 123,
 3    Name: "name",
 4    Criteria: []*ticketmatic.DupeDetectCriteria{
 5        &ticketmatic.DupeDetectCriteria{
 6            Field: "email",
 7            Matcher: "exact",
 8        },
 9    },
10    Createdts: ticketmatic.NewTime(ticketmatic.MustParseTime("2014-09-26 15:24:36")),
11    Lastupdatets: ticketmatic.NewTime(ticketmatic.MustParseTime("2014-09-26 15:24:36")),
12}

Request

1GET /api/1/{accountname}/settings/system/dupedetectrules/{id} HTTP/1.1

Response

 1HTTP/1.1 200 OK
 2Content-Type: application/json
 3
 4{
 5    "id": 123,
 6    "name": "name",
 7    "criteria": [
 8        {
 9            "field": "email",
10            "matcher": "exact"
11        }
12    ],
13    "createdts": "2014-09-26 15:24:36",
14    "lastupdatets": "2014-09-26 15:24:36"
15}

Result fields

FieldDescription
id
int

Unique ID

Example value:123
name
string

Rule name

Example value:"name"
criteria

Criteria for matching

Any contact that matches all of these criteria is listed as a match

Example value:[ { "field": "email", "matcher": "exact" } ]
createdts
timestamp

Created timestamp

Example value:"2014-09-26 15:24:36"
lastupdatets
timestamp

Last updated timestamp

Example value:"2014-09-26 15:24:36"

Type reference: DupeDetectRule