@iblai/iblai-api 4.266.0-ai → 4.267.0-ai

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/dist/index.cjs.js +758 -64
  2. package/dist/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +758 -65
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/index.umd.js +758 -64
  6. package/dist/index.umd.js.map +1 -1
  7. package/dist/types/index.d.ts +5 -0
  8. package/dist/types/models/Deal.d.ts +12 -0
  9. package/dist/types/models/Organization.d.ts +12 -0
  10. package/dist/types/models/PaginatedTagList.d.ts +7 -0
  11. package/dist/types/models/PatchedDeal.d.ts +12 -0
  12. package/dist/types/models/PatchedOrganization.d.ts +12 -0
  13. package/dist/types/models/PatchedPerson.d.ts +12 -0
  14. package/dist/types/models/PatchedTag.d.ts +30 -0
  15. package/dist/types/models/Person.d.ts +12 -0
  16. package/dist/types/models/Tag.d.ts +30 -0
  17. package/dist/types/models/_TagAttachRequest.d.ts +6 -0
  18. package/dist/types/services/ActivitiesService.d.ts +1 -1
  19. package/dist/types/services/AiAccountService.d.ts +80 -14
  20. package/dist/types/services/CrmService.d.ts +185 -10
  21. package/dist/types/services/DealsService.d.ts +34 -2
  22. package/dist/types/services/IntegrationCredentialsService.d.ts +5 -1
  23. package/dist/types/services/LeadSourcesService.d.ts +1 -1
  24. package/dist/types/services/OrganizationsService.d.ts +28 -2
  25. package/dist/types/services/PersonsService.d.ts +28 -2
  26. package/dist/types/services/PipelinesService.d.ts +2 -2
  27. package/dist/types/services/TagsService.d.ts +96 -0
  28. package/package.json +1 -1
  29. package/sdk_schema.yml +1391 -36
  30. package/src/core/OpenAPI.ts +1 -1
  31. package/src/index.ts +5 -0
  32. package/src/models/Deal.ts +12 -0
  33. package/src/models/Organization.ts +12 -0
  34. package/src/models/PaginatedTagList.ts +12 -0
  35. package/src/models/PatchedDeal.ts +12 -0
  36. package/src/models/PatchedOrganization.ts +12 -0
  37. package/src/models/PatchedPerson.ts +12 -0
  38. package/src/models/PatchedTag.ts +35 -0
  39. package/src/models/Person.ts +12 -0
  40. package/src/models/Tag.ts +35 -0
  41. package/src/models/_TagAttachRequest.ts +11 -0
  42. package/src/services/ActivitiesService.ts +2 -2
  43. package/src/services/AiAccountService.ts +87 -7
  44. package/src/services/CrmService.ts +399 -14
  45. package/src/services/DealsService.ts +71 -2
  46. package/src/services/IntegrationCredentialsService.ts +6 -0
  47. package/src/services/LeadSourcesService.ts +2 -2
  48. package/src/services/OrganizationsService.ts +65 -2
  49. package/src/services/PersonsService.ts +65 -2
  50. package/src/services/PipelinesService.ts +4 -4
  51. package/src/services/TagsService.ts +201 -0
package/dist/index.cjs.js CHANGED
@@ -110,7 +110,7 @@ class CancelablePromise {
110
110
 
111
111
  const OpenAPI = {
112
112
  BASE: 'https://base.manager.iblai.app',
113
- VERSION: '4.266.0-ai-plus',
113
+ VERSION: '4.267.0-ai-plus',
114
114
  WITH_CREDENTIALS: false,
115
115
  CREDENTIALS: 'include',
116
116
  TOKEN: undefined,
@@ -2206,7 +2206,7 @@ class ActivitiesService {
2206
2206
  * Create an activity
2207
2207
  * Creates an Activity. Either `deal` or `person` must be supplied; both must belong to your Platform.
2208
2208
  *
2209
- * **Required permission:** `Ibl.CRM/Activities/write`.
2209
+ * **Required permission:** `Ibl.CRM/Activities/action`.
2210
2210
  * @returns Activity
2211
2211
  * @throws ApiError
2212
2212
  */
@@ -2220,7 +2220,7 @@ class ActivitiesService {
2220
2220
  mediaType: 'application/json',
2221
2221
  errors: {
2222
2222
  400: `Validation error.`,
2223
- 403: `Missing required permission \`Ibl.CRM/Activities/write\`.`
2223
+ 403: `Missing required permission \`Ibl.CRM/Activities/action\`.`
2224
2224
  }
2225
2225
  });
2226
2226
  }
@@ -2537,23 +2537,34 @@ class AiAccountService {
2537
2537
  * name (optional): Filter results by LLM provider name.
2538
2538
  * When name=google, returns both 'google' (service account) and
2539
2539
  * 'gemini_google_api_key' credentials if they exist.
2540
+ * unmask_sensitive_fields (optional, bool, default False):
2541
+ * If true, returns the raw unmasked credential value. Restricted
2542
+ * to credentials owned by the requested tenant — the
2543
+ * ``GlobalCredential`` fallback is suppressed when unmasking,
2544
+ * and the response is ``[]`` instead of 404 if the tenant has
2545
+ * no own credentials.
2540
2546
  *
2541
2547
  * Args:
2542
2548
  * request: The HTTP request
2543
2549
  * org: Organization key identifier
2544
2550
  *
2545
2551
  * Returns:
2546
- * Response: List of LLM credentials for the organization
2552
+ * Response: List of LLM credentials for the organization. Values
2553
+ * are masked by default; unmasked when ``unmask_sensitive_fields=true``
2554
+ * and the credential belongs to the tenant.
2547
2555
  *
2548
2556
  * Raises:
2549
- * NotFound: When organization is not found or when no credentials match the filters
2557
+ * NotFound: When organization is not found, or (in default masked
2558
+ * mode) when no credentials match the filters even after the
2559
+ * global-credential fallback.
2550
2560
  * ValidationError: When query parameters are invalid
2551
2561
  * @returns LLMCredentialResponse
2552
2562
  * @throws ApiError
2553
2563
  */
2554
2564
  static aiAccountOrgsCredentialRetrieve({
2555
2565
  org,
2556
- name
2566
+ name,
2567
+ unmaskSensitiveFields = false
2557
2568
  }) {
2558
2569
  return request(OpenAPI, {
2559
2570
  method: 'GET',
@@ -2562,7 +2573,8 @@ class AiAccountService {
2562
2573
  'org': org
2563
2574
  },
2564
2575
  query: {
2565
- 'name': name
2576
+ 'name': name,
2577
+ 'unmask_sensitive_fields': unmaskSensitiveFields
2566
2578
  }
2567
2579
  });
2568
2580
  }
@@ -2683,7 +2695,8 @@ class AiAccountService {
2683
2695
  */
2684
2696
  static aiAccountOrgsCredentialSchemaRetrieve({
2685
2697
  org,
2686
- name
2698
+ name,
2699
+ unmaskSensitiveFields = false
2687
2700
  }) {
2688
2701
  return request(OpenAPI, {
2689
2702
  method: 'GET',
@@ -2692,7 +2705,8 @@ class AiAccountService {
2692
2705
  'org': org
2693
2706
  },
2694
2707
  query: {
2695
- 'name': name
2708
+ 'name': name,
2709
+ 'unmask_sensitive_fields': unmaskSensitiveFields
2696
2710
  }
2697
2711
  });
2698
2712
  }
@@ -2859,6 +2873,15 @@ class AiAccountService {
2859
2873
  *
2860
2874
  * Query Parameters:
2861
2875
  * name (optional): Filter results by integration service name
2876
+ * unmask_sensitive_fields (optional, bool, default False):
2877
+ * If true and the requester is a platform admin for ``org``,
2878
+ * returns full unmasked credential values. Restricted to
2879
+ * credentials owned by the requested tenant — the ``main``
2880
+ * platform fallback is suppressed when unmasking, so admins
2881
+ * cannot read another tenant's or the global ``main``
2882
+ * credentials unmasked. Silently ignored for non-admins;
2883
+ * students never receive sensitive fields regardless of this
2884
+ * flag.
2862
2885
  *
2863
2886
  * Args:
2864
2887
  * request: The HTTP request
@@ -2866,9 +2889,18 @@ class AiAccountService {
2866
2889
  *
2867
2890
  * Returns:
2868
2891
  * Response: List of integration credentials for the organization
2869
- * - Students: Only allowed credentials (drive/dropbox/onedrive) with
2870
- * sensitive fields removed
2871
- * - Admins: All credentials with sensitive fields masked
2892
+ * - Students: Only credentials whose schema declares at least one
2893
+ * non-sensitive field (``is_student_visible()``), with sensitive
2894
+ * fields removed from the response
2895
+ * - Admins (default): All credentials with sensitive fields masked
2896
+ * - Admins (with ``unmask_sensitive_fields=true``): Tenant-owned
2897
+ * credentials with sensitive fields unmasked
2898
+ *
2899
+ * If the tenant has no matching credentials and
2900
+ * ``ALLOW_TENANTS_TO_USE_MAIN_LLM_CREDENTIALS`` is enabled, the
2901
+ * response falls back to credentials on the ``main`` platform
2902
+ * (still filtered by the rules above). The fallback does NOT
2903
+ * apply when ``unmask_sensitive_fields=true``.
2872
2904
  *
2873
2905
  * Raises:
2874
2906
  * NotFound: When organization is not found or when no credentials match the filters
@@ -2878,7 +2910,8 @@ class AiAccountService {
2878
2910
  */
2879
2911
  static aiAccountOrgsIntegrationCredentialRetrieve({
2880
2912
  org,
2881
- name
2913
+ name,
2914
+ unmaskSensitiveFields = false
2882
2915
  }) {
2883
2916
  return request(OpenAPI, {
2884
2917
  method: 'GET',
@@ -2887,7 +2920,8 @@ class AiAccountService {
2887
2920
  'org': org
2888
2921
  },
2889
2922
  query: {
2890
- 'name': name
2923
+ 'name': name,
2924
+ 'unmask_sensitive_fields': unmaskSensitiveFields
2891
2925
  }
2892
2926
  });
2893
2927
  }
@@ -2997,7 +3031,8 @@ class AiAccountService {
2997
3031
  */
2998
3032
  static aiAccountOrgsIntegrationCredentialSchemaRetrieve({
2999
3033
  org,
3000
- name
3034
+ name,
3035
+ unmaskSensitiveFields = false
3001
3036
  }) {
3002
3037
  return request(OpenAPI, {
3003
3038
  method: 'GET',
@@ -3006,7 +3041,8 @@ class AiAccountService {
3006
3041
  'org': org
3007
3042
  },
3008
3043
  query: {
3009
- 'name': name
3044
+ 'name': name,
3045
+ 'unmask_sensitive_fields': unmaskSensitiveFields
3010
3046
  }
3011
3047
  });
3012
3048
  }
@@ -3017,23 +3053,34 @@ class AiAccountService {
3017
3053
  * name (optional): Filter results by LLM provider name.
3018
3054
  * When name=google, returns both 'google' (service account) and
3019
3055
  * 'gemini_google_api_key' credentials if they exist.
3056
+ * unmask_sensitive_fields (optional, bool, default False):
3057
+ * If true, returns the raw unmasked credential value. Restricted
3058
+ * to credentials owned by the requested tenant — the
3059
+ * ``GlobalCredential`` fallback is suppressed when unmasking,
3060
+ * and the response is ``[]`` instead of 404 if the tenant has
3061
+ * no own credentials.
3020
3062
  *
3021
3063
  * Args:
3022
3064
  * request: The HTTP request
3023
3065
  * org: Organization key identifier
3024
3066
  *
3025
3067
  * Returns:
3026
- * Response: List of LLM credentials for the organization
3068
+ * Response: List of LLM credentials for the organization. Values
3069
+ * are masked by default; unmasked when ``unmask_sensitive_fields=true``
3070
+ * and the credential belongs to the tenant.
3027
3071
  *
3028
3072
  * Raises:
3029
- * NotFound: When organization is not found or when no credentials match the filters
3073
+ * NotFound: When organization is not found, or (in default masked
3074
+ * mode) when no credentials match the filters even after the
3075
+ * global-credential fallback.
3030
3076
  * ValidationError: When query parameters are invalid
3031
3077
  * @returns LLMCredentialResponse
3032
3078
  * @throws ApiError
3033
3079
  */
3034
3080
  static aiAccountOrgsLlmCredentialRetrieve({
3035
3081
  org,
3036
- name
3082
+ name,
3083
+ unmaskSensitiveFields = false
3037
3084
  }) {
3038
3085
  return request(OpenAPI, {
3039
3086
  method: 'GET',
@@ -3042,7 +3089,8 @@ class AiAccountService {
3042
3089
  'org': org
3043
3090
  },
3044
3091
  query: {
3045
- 'name': name
3092
+ 'name': name,
3093
+ 'unmask_sensitive_fields': unmaskSensitiveFields
3046
3094
  }
3047
3095
  });
3048
3096
  }
@@ -3163,7 +3211,8 @@ class AiAccountService {
3163
3211
  */
3164
3212
  static aiAccountOrgsMaskedIntegrationCredentialList({
3165
3213
  org,
3166
- name
3214
+ name,
3215
+ unmaskSensitiveFields = false
3167
3216
  }) {
3168
3217
  return request(OpenAPI, {
3169
3218
  method: 'GET',
@@ -3172,7 +3221,8 @@ class AiAccountService {
3172
3221
  'org': org
3173
3222
  },
3174
3223
  query: {
3175
- 'name': name
3224
+ 'name': name,
3225
+ 'unmask_sensitive_fields': unmaskSensitiveFields
3176
3226
  }
3177
3227
  });
3178
3228
  }
@@ -3197,7 +3247,8 @@ class AiAccountService {
3197
3247
  */
3198
3248
  static aiAccountOrgsMaskedLlmCredentialRetrieve({
3199
3249
  org,
3200
- name
3250
+ name,
3251
+ unmaskSensitiveFields = false
3201
3252
  }) {
3202
3253
  return request(OpenAPI, {
3203
3254
  method: 'GET',
@@ -3206,7 +3257,8 @@ class AiAccountService {
3206
3257
  'org': org
3207
3258
  },
3208
3259
  query: {
3209
- 'name': name
3260
+ 'name': name,
3261
+ 'unmask_sensitive_fields': unmaskSensitiveFields
3210
3262
  }
3211
3263
  });
3212
3264
  }
@@ -45073,7 +45125,7 @@ class CrmService {
45073
45125
  * Create an activity
45074
45126
  * Creates an Activity. Either `deal` or `person` must be supplied; both must belong to your Platform.
45075
45127
  *
45076
- * **Required permission:** `Ibl.CRM/Activities/write`.
45128
+ * **Required permission:** `Ibl.CRM/Activities/action`.
45077
45129
  * @returns Activity
45078
45130
  * @throws ApiError
45079
45131
  */
@@ -45087,7 +45139,7 @@ class CrmService {
45087
45139
  mediaType: 'application/json',
45088
45140
  errors: {
45089
45141
  400: `Validation error.`,
45090
- 403: `Missing required permission \`Ibl.CRM/Activities/write\`.`
45142
+ 403: `Missing required permission \`Ibl.CRM/Activities/action\`.`
45091
45143
  }
45092
45144
  });
45093
45145
  }
@@ -45236,7 +45288,8 @@ class CrmService {
45236
45288
  pipeline,
45237
45289
  source,
45238
45290
  stage,
45239
- status
45291
+ status,
45292
+ tags
45240
45293
  }) {
45241
45294
  return request(OpenAPI, {
45242
45295
  method: 'GET',
@@ -45255,7 +45308,8 @@ class CrmService {
45255
45308
  'pipeline': pipeline,
45256
45309
  'source': source,
45257
45310
  'stage': stage,
45258
- 'status': status
45311
+ 'status': status,
45312
+ 'tags': tags
45259
45313
  },
45260
45314
  errors: {
45261
45315
  401: `Authentication required.`,
@@ -45267,7 +45321,7 @@ class CrmService {
45267
45321
  * Create a deal
45268
45322
  * Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
45269
45323
  *
45270
- * **Required permission:** `Ibl.CRM/Deals/write`.
45324
+ * **Required permission:** `Ibl.CRM/Deals/action`.
45271
45325
  * @returns Deal
45272
45326
  * @throws ApiError
45273
45327
  */
@@ -45281,7 +45335,7 @@ class CrmService {
45281
45335
  mediaType: 'application/json',
45282
45336
  errors: {
45283
45337
  400: `Validation error.`,
45284
- 403: `Missing required permission \`Ibl.CRM/Deals/write\`.`
45338
+ 403: `Missing required permission \`Ibl.CRM/Deals/action\`.`
45285
45339
  }
45286
45340
  });
45287
45341
  }
@@ -45439,6 +45493,59 @@ class CrmService {
45439
45493
  }
45440
45494
  });
45441
45495
  }
45496
+ /**
45497
+ * Attach a tag to this record
45498
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
45499
+ *
45500
+ * **Required permission:** `Ibl.CRM/Tags/write`.
45501
+ * @returns any No response body
45502
+ * @throws ApiError
45503
+ */
45504
+ static crmDealsTagsCreate({
45505
+ id,
45506
+ requestBody
45507
+ }) {
45508
+ return request(OpenAPI, {
45509
+ method: 'POST',
45510
+ url: '/api/crm/deals/{id}/tags/',
45511
+ path: {
45512
+ 'id': id
45513
+ },
45514
+ body: requestBody,
45515
+ mediaType: 'application/json',
45516
+ errors: {
45517
+ 400: `No response body`,
45518
+ 403: `No response body`,
45519
+ 404: `No response body`,
45520
+ 409: `No response body`
45521
+ }
45522
+ });
45523
+ }
45524
+ /**
45525
+ * Detach a tag from this record
45526
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
45527
+ *
45528
+ * **Required permission:** `Ibl.CRM/Tags/write`.
45529
+ * @returns void
45530
+ * @throws ApiError
45531
+ */
45532
+ static crmDealsTagsDestroy({
45533
+ id,
45534
+ tagId
45535
+ }) {
45536
+ return request(OpenAPI, {
45537
+ method: 'DELETE',
45538
+ url: '/api/crm/deals/{id}/tags/{tag_id}/',
45539
+ path: {
45540
+ 'id': id,
45541
+ 'tag_id': tagId
45542
+ },
45543
+ errors: {
45544
+ 403: `No response body`,
45545
+ 404: `No response body`
45546
+ }
45547
+ });
45548
+ }
45442
45549
  /**
45443
45550
  * Mark a deal as won
45444
45551
  * Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
@@ -45499,7 +45606,7 @@ class CrmService {
45499
45606
  * Create a lead source
45500
45607
  * Creates a new LeadSource in your Platform. `code` must be unique.
45501
45608
  *
45502
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
45609
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
45503
45610
  * @returns LeadSource
45504
45611
  * @throws ApiError
45505
45612
  */
@@ -45513,7 +45620,7 @@ class CrmService {
45513
45620
  mediaType: 'application/json',
45514
45621
  errors: {
45515
45622
  400: `Validation error.`,
45516
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
45623
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`
45517
45624
  }
45518
45625
  });
45519
45626
  }
@@ -45629,7 +45736,8 @@ class CrmService {
45629
45736
  name,
45630
45737
  owner,
45631
45738
  page,
45632
- pageSize
45739
+ pageSize,
45740
+ tags
45633
45741
  }) {
45634
45742
  return request(OpenAPI, {
45635
45743
  method: 'GET',
@@ -45638,7 +45746,8 @@ class CrmService {
45638
45746
  'name': name,
45639
45747
  'owner': owner,
45640
45748
  'page': page,
45641
- 'page_size': pageSize
45749
+ 'page_size': pageSize,
45750
+ 'tags': tags
45642
45751
  },
45643
45752
  errors: {
45644
45753
  401: `Authentication required.`,
@@ -45650,7 +45759,7 @@ class CrmService {
45650
45759
  * Create an organization
45651
45760
  * Creates a new organization in your Platform. The Platform is inferred from your credentials. `name` must be unique within your Platform.
45652
45761
  *
45653
- * **Required permission:** `Ibl.CRM/Organizations/write`.
45762
+ * **Required permission:** `Ibl.CRM/Organizations/action`.
45654
45763
  * @returns Organization
45655
45764
  * @throws ApiError
45656
45765
  */
@@ -45664,7 +45773,7 @@ class CrmService {
45664
45773
  mediaType: 'application/json',
45665
45774
  errors: {
45666
45775
  400: `Validation error (for example, duplicate name).`,
45667
- 403: `Missing required permission \`Ibl.CRM/Organizations/write\`.`
45776
+ 403: `Missing required permission \`Ibl.CRM/Organizations/action\`.`
45668
45777
  }
45669
45778
  });
45670
45779
  }
@@ -45768,6 +45877,59 @@ class CrmService {
45768
45877
  }
45769
45878
  });
45770
45879
  }
45880
+ /**
45881
+ * Attach a tag to this record
45882
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
45883
+ *
45884
+ * **Required permission:** `Ibl.CRM/Tags/write`.
45885
+ * @returns any No response body
45886
+ * @throws ApiError
45887
+ */
45888
+ static crmOrganizationsTagsCreate({
45889
+ id,
45890
+ requestBody
45891
+ }) {
45892
+ return request(OpenAPI, {
45893
+ method: 'POST',
45894
+ url: '/api/crm/organizations/{id}/tags/',
45895
+ path: {
45896
+ 'id': id
45897
+ },
45898
+ body: requestBody,
45899
+ mediaType: 'application/json',
45900
+ errors: {
45901
+ 400: `No response body`,
45902
+ 403: `No response body`,
45903
+ 404: `No response body`,
45904
+ 409: `No response body`
45905
+ }
45906
+ });
45907
+ }
45908
+ /**
45909
+ * Detach a tag from this record
45910
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
45911
+ *
45912
+ * **Required permission:** `Ibl.CRM/Tags/write`.
45913
+ * @returns void
45914
+ * @throws ApiError
45915
+ */
45916
+ static crmOrganizationsTagsDestroy({
45917
+ id,
45918
+ tagId
45919
+ }) {
45920
+ return request(OpenAPI, {
45921
+ method: 'DELETE',
45922
+ url: '/api/crm/organizations/{id}/tags/{tag_id}/',
45923
+ path: {
45924
+ 'id': id,
45925
+ 'tag_id': tagId
45926
+ },
45927
+ errors: {
45928
+ 403: `No response body`,
45929
+ 404: `No response body`
45930
+ }
45931
+ });
45932
+ }
45771
45933
  /**
45772
45934
  * List persons
45773
45935
  * Returns a paginated list of persons in your Platform. Supports filtering by `lifecycle_stage`, `owner`, `organization`, `created_at__gte`/`created_at__lte`, and `metadata__has_key`.
@@ -45784,7 +45946,8 @@ class CrmService {
45784
45946
  organization,
45785
45947
  owner,
45786
45948
  page,
45787
- pageSize
45949
+ pageSize,
45950
+ tags
45788
45951
  }) {
45789
45952
  return request(OpenAPI, {
45790
45953
  method: 'GET',
@@ -45797,7 +45960,8 @@ class CrmService {
45797
45960
  'organization': organization,
45798
45961
  'owner': owner,
45799
45962
  'page': page,
45800
- 'page_size': pageSize
45963
+ 'page_size': pageSize,
45964
+ 'tags': tags
45801
45965
  },
45802
45966
  errors: {
45803
45967
  401: `Authentication required.`,
@@ -45809,7 +45973,7 @@ class CrmService {
45809
45973
  * Create a person
45810
45974
  * Creates a new person in your Platform. The Platform is inferred from your credentials. If `organization` is supplied, it must reference an organization in your Platform.
45811
45975
  *
45812
- * **Required permission:** `Ibl.CRM/Persons/write`.
45976
+ * **Required permission:** `Ibl.CRM/Persons/action`.
45813
45977
  * @returns Person
45814
45978
  * @throws ApiError
45815
45979
  */
@@ -45823,7 +45987,7 @@ class CrmService {
45823
45987
  mediaType: 'application/json',
45824
45988
  errors: {
45825
45989
  400: `Validation error.`,
45826
- 403: `Missing required permission \`Ibl.CRM/Persons/write\`.`
45990
+ 403: `Missing required permission \`Ibl.CRM/Persons/action\`.`
45827
45991
  }
45828
45992
  });
45829
45993
  }
@@ -45986,6 +46150,59 @@ class CrmService {
45986
46150
  }
45987
46151
  });
45988
46152
  }
46153
+ /**
46154
+ * Attach a tag to this record
46155
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
46156
+ *
46157
+ * **Required permission:** `Ibl.CRM/Tags/write`.
46158
+ * @returns any No response body
46159
+ * @throws ApiError
46160
+ */
46161
+ static crmPersonsTagsCreate({
46162
+ id,
46163
+ requestBody
46164
+ }) {
46165
+ return request(OpenAPI, {
46166
+ method: 'POST',
46167
+ url: '/api/crm/persons/{id}/tags/',
46168
+ path: {
46169
+ 'id': id
46170
+ },
46171
+ body: requestBody,
46172
+ mediaType: 'application/json',
46173
+ errors: {
46174
+ 400: `No response body`,
46175
+ 403: `No response body`,
46176
+ 404: `No response body`,
46177
+ 409: `No response body`
46178
+ }
46179
+ });
46180
+ }
46181
+ /**
46182
+ * Detach a tag from this record
46183
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
46184
+ *
46185
+ * **Required permission:** `Ibl.CRM/Tags/write`.
46186
+ * @returns void
46187
+ * @throws ApiError
46188
+ */
46189
+ static crmPersonsTagsDestroy({
46190
+ id,
46191
+ tagId
46192
+ }) {
46193
+ return request(OpenAPI, {
46194
+ method: 'DELETE',
46195
+ url: '/api/crm/persons/{id}/tags/{tag_id}/',
46196
+ path: {
46197
+ 'id': id,
46198
+ 'tag_id': tagId
46199
+ },
46200
+ errors: {
46201
+ 403: `No response body`,
46202
+ 404: `No response body`
46203
+ }
46204
+ });
46205
+ }
45989
46206
  /**
45990
46207
  * Merge duplicate persons into a primary
45991
46208
  * Marks each person in `duplicate_ids` as inactive and reports how many related records (deals, activities, tags) were re-parented onto `primary_id`.
@@ -46046,7 +46263,7 @@ class CrmService {
46046
46263
  * Create a pipeline
46047
46264
  * Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
46048
46265
  *
46049
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
46266
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
46050
46267
  * @returns Pipeline
46051
46268
  * @throws ApiError
46052
46269
  */
@@ -46060,7 +46277,7 @@ class CrmService {
46060
46277
  mediaType: 'application/json',
46061
46278
  errors: {
46062
46279
  400: `Validation error.`,
46063
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
46280
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`
46064
46281
  }
46065
46282
  });
46066
46283
  }
@@ -46103,7 +46320,7 @@ class CrmService {
46103
46320
  * Create a stage
46104
46321
  * Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
46105
46322
  *
46106
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
46323
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
46107
46324
  * @returns PipelineStage
46108
46325
  * @throws ApiError
46109
46326
  */
@@ -46121,7 +46338,7 @@ class CrmService {
46121
46338
  mediaType: 'application/json',
46122
46339
  errors: {
46123
46340
  400: `Validation error.`,
46124
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
46341
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`,
46125
46342
  404: `Pipeline not found.`
46126
46343
  }
46127
46344
  });
@@ -46336,6 +46553,159 @@ class CrmService {
46336
46553
  }
46337
46554
  });
46338
46555
  }
46556
+ /**
46557
+ * List tags
46558
+ * Returns a paginated list of Tags in your Platform. Supports filtering by `name` (case-insensitive substring) and `created_at__gte`/`created_at__lte` ISO timestamp ranges.
46559
+ *
46560
+ * **Required permission:** `Ibl.CRM/Tags/list`.
46561
+ * @returns PaginatedTagList
46562
+ * @throws ApiError
46563
+ */
46564
+ static crmTagsList({
46565
+ createdAtGte,
46566
+ createdAtLte,
46567
+ name,
46568
+ page,
46569
+ pageSize
46570
+ }) {
46571
+ return request(OpenAPI, {
46572
+ method: 'GET',
46573
+ url: '/api/crm/tags/',
46574
+ query: {
46575
+ 'created_at__gte': createdAtGte,
46576
+ 'created_at__lte': createdAtLte,
46577
+ 'name': name,
46578
+ 'page': page,
46579
+ 'page_size': pageSize
46580
+ },
46581
+ errors: {
46582
+ 401: `Authentication required.`,
46583
+ 403: `Missing required permission \`Ibl.CRM/Tags/list\`.`
46584
+ }
46585
+ });
46586
+ }
46587
+ /**
46588
+ * Create a tag
46589
+ * Creates a new Tag in your Platform. `name` must be unique within your Platform; supply `color` as a `#RRGGBB` hex string (defaults to `#888888`).
46590
+ *
46591
+ * **Required permission:** `Ibl.CRM/Tags/action`.
46592
+ * @returns Tag
46593
+ * @throws ApiError
46594
+ */
46595
+ static crmTagsCreate({
46596
+ requestBody
46597
+ }) {
46598
+ return request(OpenAPI, {
46599
+ method: 'POST',
46600
+ url: '/api/crm/tags/',
46601
+ body: requestBody,
46602
+ mediaType: 'application/json',
46603
+ errors: {
46604
+ 400: `Validation error (duplicate name, bad color, etc.).`,
46605
+ 403: `Missing required permission \`Ibl.CRM/Tags/action\`.`
46606
+ }
46607
+ });
46608
+ }
46609
+ /**
46610
+ * Retrieve a tag
46611
+ * Returns a single Tag by id.
46612
+ *
46613
+ * **Required permission:** `Ibl.CRM/Tags/read`.
46614
+ * @returns Tag
46615
+ * @throws ApiError
46616
+ */
46617
+ static crmTagsRetrieve({
46618
+ id
46619
+ }) {
46620
+ return request(OpenAPI, {
46621
+ method: 'GET',
46622
+ url: '/api/crm/tags/{id}/',
46623
+ path: {
46624
+ 'id': id
46625
+ },
46626
+ errors: {
46627
+ 403: `Missing required permission \`Ibl.CRM/Tags/read\`.`,
46628
+ 404: `Tag not found.`
46629
+ }
46630
+ });
46631
+ }
46632
+ /**
46633
+ * Replace a tag
46634
+ * Replaces all editable fields on the Tag.
46635
+ *
46636
+ * **Required permission:** `Ibl.CRM/Tags/write`.
46637
+ * @returns Tag
46638
+ * @throws ApiError
46639
+ */
46640
+ static crmTagsUpdate({
46641
+ id,
46642
+ requestBody
46643
+ }) {
46644
+ return request(OpenAPI, {
46645
+ method: 'PUT',
46646
+ url: '/api/crm/tags/{id}/',
46647
+ path: {
46648
+ 'id': id
46649
+ },
46650
+ body: requestBody,
46651
+ mediaType: 'application/json',
46652
+ errors: {
46653
+ 400: `Validation error.`,
46654
+ 403: `Missing required permission \`Ibl.CRM/Tags/write\`.`,
46655
+ 404: `Tag not found.`
46656
+ }
46657
+ });
46658
+ }
46659
+ /**
46660
+ * Update a tag
46661
+ * Updates only the supplied fields on the Tag (typically `name` or `color`).
46662
+ *
46663
+ * **Required permission:** `Ibl.CRM/Tags/write`.
46664
+ * @returns Tag
46665
+ * @throws ApiError
46666
+ */
46667
+ static crmTagsPartialUpdate({
46668
+ id,
46669
+ requestBody
46670
+ }) {
46671
+ return request(OpenAPI, {
46672
+ method: 'PATCH',
46673
+ url: '/api/crm/tags/{id}/',
46674
+ path: {
46675
+ 'id': id
46676
+ },
46677
+ body: requestBody,
46678
+ mediaType: 'application/json',
46679
+ errors: {
46680
+ 400: `Validation error.`,
46681
+ 403: `Missing required permission \`Ibl.CRM/Tags/write\`.`,
46682
+ 404: `Tag not found.`
46683
+ }
46684
+ });
46685
+ }
46686
+ /**
46687
+ * Delete a tag
46688
+ * Deletes the Tag. All attachments to Persons, Organizations, and Deals are removed atomically via cascade.
46689
+ *
46690
+ * **Required permission:** `Ibl.CRM/Tags/delete`.
46691
+ * @returns void
46692
+ * @throws ApiError
46693
+ */
46694
+ static crmTagsDestroy({
46695
+ id
46696
+ }) {
46697
+ return request(OpenAPI, {
46698
+ method: 'DELETE',
46699
+ url: '/api/crm/tags/{id}/',
46700
+ path: {
46701
+ 'id': id
46702
+ },
46703
+ errors: {
46704
+ 403: `Missing required permission \`Ibl.CRM/Tags/delete\`.`,
46705
+ 404: `Tag not found.`
46706
+ }
46707
+ });
46708
+ }
46339
46709
  }
46340
46710
 
46341
46711
  class CustomDomainsService {
@@ -46450,7 +46820,8 @@ class DealsService {
46450
46820
  pipeline,
46451
46821
  source,
46452
46822
  stage,
46453
- status
46823
+ status,
46824
+ tags
46454
46825
  }) {
46455
46826
  return request(OpenAPI, {
46456
46827
  method: 'GET',
@@ -46469,7 +46840,8 @@ class DealsService {
46469
46840
  'pipeline': pipeline,
46470
46841
  'source': source,
46471
46842
  'stage': stage,
46472
- 'status': status
46843
+ 'status': status,
46844
+ 'tags': tags
46473
46845
  },
46474
46846
  errors: {
46475
46847
  401: `Authentication required.`,
@@ -46481,7 +46853,7 @@ class DealsService {
46481
46853
  * Create a deal
46482
46854
  * Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
46483
46855
  *
46484
- * **Required permission:** `Ibl.CRM/Deals/write`.
46856
+ * **Required permission:** `Ibl.CRM/Deals/action`.
46485
46857
  * @returns Deal
46486
46858
  * @throws ApiError
46487
46859
  */
@@ -46495,7 +46867,7 @@ class DealsService {
46495
46867
  mediaType: 'application/json',
46496
46868
  errors: {
46497
46869
  400: `Validation error.`,
46498
- 403: `Missing required permission \`Ibl.CRM/Deals/write\`.`
46870
+ 403: `Missing required permission \`Ibl.CRM/Deals/action\`.`
46499
46871
  }
46500
46872
  });
46501
46873
  }
@@ -46653,6 +47025,59 @@ class DealsService {
46653
47025
  }
46654
47026
  });
46655
47027
  }
47028
+ /**
47029
+ * Attach a tag to this record
47030
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
47031
+ *
47032
+ * **Required permission:** `Ibl.CRM/Tags/write`.
47033
+ * @returns any No response body
47034
+ * @throws ApiError
47035
+ */
47036
+ static dealsTagsCreate({
47037
+ id,
47038
+ requestBody
47039
+ }) {
47040
+ return request(OpenAPI, {
47041
+ method: 'POST',
47042
+ url: '/deals/{id}/tags/',
47043
+ path: {
47044
+ 'id': id
47045
+ },
47046
+ body: requestBody,
47047
+ mediaType: 'application/json',
47048
+ errors: {
47049
+ 400: `No response body`,
47050
+ 403: `No response body`,
47051
+ 404: `No response body`,
47052
+ 409: `No response body`
47053
+ }
47054
+ });
47055
+ }
47056
+ /**
47057
+ * Detach a tag from this record
47058
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
47059
+ *
47060
+ * **Required permission:** `Ibl.CRM/Tags/write`.
47061
+ * @returns void
47062
+ * @throws ApiError
47063
+ */
47064
+ static dealsTagsDestroy({
47065
+ id,
47066
+ tagId
47067
+ }) {
47068
+ return request(OpenAPI, {
47069
+ method: 'DELETE',
47070
+ url: '/deals/{id}/tags/{tag_id}/',
47071
+ path: {
47072
+ 'id': id,
47073
+ 'tag_id': tagId
47074
+ },
47075
+ errors: {
47076
+ 403: `No response body`,
47077
+ 404: `No response body`
47078
+ }
47079
+ });
47080
+ }
46656
47081
  /**
46657
47082
  * Mark a deal as won
46658
47083
  * Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
@@ -46813,7 +47238,8 @@ class IntegrationCredentialsService {
46813
47238
  */
46814
47239
  static aiAccountOrgsIntegrationCredentialSchemaV2List({
46815
47240
  org,
46816
- name
47241
+ name,
47242
+ unmaskSensitiveFields = false
46817
47243
  }) {
46818
47244
  return request(OpenAPI, {
46819
47245
  method: 'GET',
@@ -46822,7 +47248,8 @@ class IntegrationCredentialsService {
46822
47248
  'org': org
46823
47249
  },
46824
47250
  query: {
46825
- 'name': name
47251
+ 'name': name,
47252
+ 'unmask_sensitive_fields': unmaskSensitiveFields
46826
47253
  }
46827
47254
  });
46828
47255
  }
@@ -46882,7 +47309,7 @@ class LeadSourcesService {
46882
47309
  * Create a lead source
46883
47310
  * Creates a new LeadSource in your Platform. `code` must be unique.
46884
47311
  *
46885
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
47312
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
46886
47313
  * @returns LeadSource
46887
47314
  * @throws ApiError
46888
47315
  */
@@ -46896,7 +47323,7 @@ class LeadSourcesService {
46896
47323
  mediaType: 'application/json',
46897
47324
  errors: {
46898
47325
  400: `Validation error.`,
46899
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
47326
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`
46900
47327
  }
46901
47328
  });
46902
47329
  }
@@ -47899,7 +48326,8 @@ class OrganizationsService {
47899
48326
  name,
47900
48327
  owner,
47901
48328
  page,
47902
- pageSize
48329
+ pageSize,
48330
+ tags
47903
48331
  }) {
47904
48332
  return request(OpenAPI, {
47905
48333
  method: 'GET',
@@ -47908,7 +48336,8 @@ class OrganizationsService {
47908
48336
  'name': name,
47909
48337
  'owner': owner,
47910
48338
  'page': page,
47911
- 'page_size': pageSize
48339
+ 'page_size': pageSize,
48340
+ 'tags': tags
47912
48341
  },
47913
48342
  errors: {
47914
48343
  401: `Authentication required.`,
@@ -47920,7 +48349,7 @@ class OrganizationsService {
47920
48349
  * Create an organization
47921
48350
  * Creates a new organization in your Platform. The Platform is inferred from your credentials. `name` must be unique within your Platform.
47922
48351
  *
47923
- * **Required permission:** `Ibl.CRM/Organizations/write`.
48352
+ * **Required permission:** `Ibl.CRM/Organizations/action`.
47924
48353
  * @returns Organization
47925
48354
  * @throws ApiError
47926
48355
  */
@@ -47934,7 +48363,7 @@ class OrganizationsService {
47934
48363
  mediaType: 'application/json',
47935
48364
  errors: {
47936
48365
  400: `Validation error (for example, duplicate name).`,
47937
- 403: `Missing required permission \`Ibl.CRM/Organizations/write\`.`
48366
+ 403: `Missing required permission \`Ibl.CRM/Organizations/action\`.`
47938
48367
  }
47939
48368
  });
47940
48369
  }
@@ -48038,6 +48467,59 @@ class OrganizationsService {
48038
48467
  }
48039
48468
  });
48040
48469
  }
48470
+ /**
48471
+ * Attach a tag to this record
48472
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
48473
+ *
48474
+ * **Required permission:** `Ibl.CRM/Tags/write`.
48475
+ * @returns any No response body
48476
+ * @throws ApiError
48477
+ */
48478
+ static organizationsTagsCreate({
48479
+ id,
48480
+ requestBody
48481
+ }) {
48482
+ return request(OpenAPI, {
48483
+ method: 'POST',
48484
+ url: '/organizations/{id}/tags/',
48485
+ path: {
48486
+ 'id': id
48487
+ },
48488
+ body: requestBody,
48489
+ mediaType: 'application/json',
48490
+ errors: {
48491
+ 400: `No response body`,
48492
+ 403: `No response body`,
48493
+ 404: `No response body`,
48494
+ 409: `No response body`
48495
+ }
48496
+ });
48497
+ }
48498
+ /**
48499
+ * Detach a tag from this record
48500
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
48501
+ *
48502
+ * **Required permission:** `Ibl.CRM/Tags/write`.
48503
+ * @returns void
48504
+ * @throws ApiError
48505
+ */
48506
+ static organizationsTagsDestroy({
48507
+ id,
48508
+ tagId
48509
+ }) {
48510
+ return request(OpenAPI, {
48511
+ method: 'DELETE',
48512
+ url: '/organizations/{id}/tags/{tag_id}/',
48513
+ path: {
48514
+ 'id': id,
48515
+ 'tag_id': tagId
48516
+ },
48517
+ errors: {
48518
+ 403: `No response body`,
48519
+ 404: `No response body`
48520
+ }
48521
+ });
48522
+ }
48041
48523
  }
48042
48524
 
48043
48525
  class PersonsService {
@@ -48057,7 +48539,8 @@ class PersonsService {
48057
48539
  organization,
48058
48540
  owner,
48059
48541
  page,
48060
- pageSize
48542
+ pageSize,
48543
+ tags
48061
48544
  }) {
48062
48545
  return request(OpenAPI, {
48063
48546
  method: 'GET',
@@ -48070,7 +48553,8 @@ class PersonsService {
48070
48553
  'organization': organization,
48071
48554
  'owner': owner,
48072
48555
  'page': page,
48073
- 'page_size': pageSize
48556
+ 'page_size': pageSize,
48557
+ 'tags': tags
48074
48558
  },
48075
48559
  errors: {
48076
48560
  401: `Authentication required.`,
@@ -48082,7 +48566,7 @@ class PersonsService {
48082
48566
  * Create a person
48083
48567
  * Creates a new person in your Platform. The Platform is inferred from your credentials. If `organization` is supplied, it must reference an organization in your Platform.
48084
48568
  *
48085
- * **Required permission:** `Ibl.CRM/Persons/write`.
48569
+ * **Required permission:** `Ibl.CRM/Persons/action`.
48086
48570
  * @returns Person
48087
48571
  * @throws ApiError
48088
48572
  */
@@ -48096,7 +48580,7 @@ class PersonsService {
48096
48580
  mediaType: 'application/json',
48097
48581
  errors: {
48098
48582
  400: `Validation error.`,
48099
- 403: `Missing required permission \`Ibl.CRM/Persons/write\`.`
48583
+ 403: `Missing required permission \`Ibl.CRM/Persons/action\`.`
48100
48584
  }
48101
48585
  });
48102
48586
  }
@@ -48259,6 +48743,59 @@ class PersonsService {
48259
48743
  }
48260
48744
  });
48261
48745
  }
48746
+ /**
48747
+ * Attach a tag to this record
48748
+ * Attaches an existing Tag to this record. Both the Tag and the record must belong to your Platform. Returns `409 Conflict` with the existing `assignment_id` if the tag is already attached.
48749
+ *
48750
+ * **Required permission:** `Ibl.CRM/Tags/write`.
48751
+ * @returns any No response body
48752
+ * @throws ApiError
48753
+ */
48754
+ static personsTagsCreate({
48755
+ id,
48756
+ requestBody
48757
+ }) {
48758
+ return request(OpenAPI, {
48759
+ method: 'POST',
48760
+ url: '/persons/{id}/tags/',
48761
+ path: {
48762
+ 'id': id
48763
+ },
48764
+ body: requestBody,
48765
+ mediaType: 'application/json',
48766
+ errors: {
48767
+ 400: `No response body`,
48768
+ 403: `No response body`,
48769
+ 404: `No response body`,
48770
+ 409: `No response body`
48771
+ }
48772
+ });
48773
+ }
48774
+ /**
48775
+ * Detach a tag from this record
48776
+ * Removes the Tag with id `tag_id` from this record. Returns `404` if the tag was not attached.
48777
+ *
48778
+ * **Required permission:** `Ibl.CRM/Tags/write`.
48779
+ * @returns void
48780
+ * @throws ApiError
48781
+ */
48782
+ static personsTagsDestroy({
48783
+ id,
48784
+ tagId
48785
+ }) {
48786
+ return request(OpenAPI, {
48787
+ method: 'DELETE',
48788
+ url: '/persons/{id}/tags/{tag_id}/',
48789
+ path: {
48790
+ 'id': id,
48791
+ 'tag_id': tagId
48792
+ },
48793
+ errors: {
48794
+ 403: `No response body`,
48795
+ 404: `No response body`
48796
+ }
48797
+ });
48798
+ }
48262
48799
  /**
48263
48800
  * Merge duplicate persons into a primary
48264
48801
  * Marks each person in `duplicate_ids` as inactive and reports how many related records (deals, activities, tags) were re-parented onto `primary_id`.
@@ -48322,7 +48859,7 @@ class PipelinesService {
48322
48859
  * Create a pipeline
48323
48860
  * Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
48324
48861
  *
48325
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
48862
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
48326
48863
  * @returns Pipeline
48327
48864
  * @throws ApiError
48328
48865
  */
@@ -48336,7 +48873,7 @@ class PipelinesService {
48336
48873
  mediaType: 'application/json',
48337
48874
  errors: {
48338
48875
  400: `Validation error.`,
48339
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
48876
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`
48340
48877
  }
48341
48878
  });
48342
48879
  }
@@ -48379,7 +48916,7 @@ class PipelinesService {
48379
48916
  * Create a stage
48380
48917
  * Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
48381
48918
  *
48382
- * **Required permission:** `Ibl.CRM/Pipelines/write`.
48919
+ * **Required permission:** `Ibl.CRM/Pipelines/action`.
48383
48920
  * @returns PipelineStage
48384
48921
  * @throws ApiError
48385
48922
  */
@@ -48397,7 +48934,7 @@ class PipelinesService {
48397
48934
  mediaType: 'application/json',
48398
48935
  errors: {
48399
48936
  400: `Validation error.`,
48400
- 403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
48937
+ 403: `Missing required permission \`Ibl.CRM/Pipelines/action\`.`,
48401
48938
  404: `Pipeline not found.`
48402
48939
  }
48403
48940
  });
@@ -51433,6 +51970,162 @@ class SkillsService {
51433
51970
  }
51434
51971
  }
51435
51972
 
51973
+ class TagsService {
51974
+ /**
51975
+ * List tags
51976
+ * Returns a paginated list of Tags in your Platform. Supports filtering by `name` (case-insensitive substring) and `created_at__gte`/`created_at__lte` ISO timestamp ranges.
51977
+ *
51978
+ * **Required permission:** `Ibl.CRM/Tags/list`.
51979
+ * @returns PaginatedTagList
51980
+ * @throws ApiError
51981
+ */
51982
+ static tagsList({
51983
+ createdAtGte,
51984
+ createdAtLte,
51985
+ name,
51986
+ page,
51987
+ pageSize
51988
+ }) {
51989
+ return request(OpenAPI, {
51990
+ method: 'GET',
51991
+ url: '/tags/',
51992
+ query: {
51993
+ 'created_at__gte': createdAtGte,
51994
+ 'created_at__lte': createdAtLte,
51995
+ 'name': name,
51996
+ 'page': page,
51997
+ 'page_size': pageSize
51998
+ },
51999
+ errors: {
52000
+ 401: `Authentication required.`,
52001
+ 403: `Missing required permission \`Ibl.CRM/Tags/list\`.`
52002
+ }
52003
+ });
52004
+ }
52005
+ /**
52006
+ * Create a tag
52007
+ * Creates a new Tag in your Platform. `name` must be unique within your Platform; supply `color` as a `#RRGGBB` hex string (defaults to `#888888`).
52008
+ *
52009
+ * **Required permission:** `Ibl.CRM/Tags/action`.
52010
+ * @returns Tag
52011
+ * @throws ApiError
52012
+ */
52013
+ static tagsCreate({
52014
+ requestBody
52015
+ }) {
52016
+ return request(OpenAPI, {
52017
+ method: 'POST',
52018
+ url: '/tags/',
52019
+ body: requestBody,
52020
+ mediaType: 'application/json',
52021
+ errors: {
52022
+ 400: `Validation error (duplicate name, bad color, etc.).`,
52023
+ 403: `Missing required permission \`Ibl.CRM/Tags/action\`.`
52024
+ }
52025
+ });
52026
+ }
52027
+ /**
52028
+ * Retrieve a tag
52029
+ * Returns a single Tag by id.
52030
+ *
52031
+ * **Required permission:** `Ibl.CRM/Tags/read`.
52032
+ * @returns Tag
52033
+ * @throws ApiError
52034
+ */
52035
+ static tagsRetrieve({
52036
+ id
52037
+ }) {
52038
+ return request(OpenAPI, {
52039
+ method: 'GET',
52040
+ url: '/tags/{id}/',
52041
+ path: {
52042
+ 'id': id
52043
+ },
52044
+ errors: {
52045
+ 403: `Missing required permission \`Ibl.CRM/Tags/read\`.`,
52046
+ 404: `Tag not found.`
52047
+ }
52048
+ });
52049
+ }
52050
+ /**
52051
+ * Replace a tag
52052
+ * Replaces all editable fields on the Tag.
52053
+ *
52054
+ * **Required permission:** `Ibl.CRM/Tags/write`.
52055
+ * @returns Tag
52056
+ * @throws ApiError
52057
+ */
52058
+ static tagsUpdate({
52059
+ id,
52060
+ requestBody
52061
+ }) {
52062
+ return request(OpenAPI, {
52063
+ method: 'PUT',
52064
+ url: '/tags/{id}/',
52065
+ path: {
52066
+ 'id': id
52067
+ },
52068
+ body: requestBody,
52069
+ mediaType: 'application/json',
52070
+ errors: {
52071
+ 400: `Validation error.`,
52072
+ 403: `Missing required permission \`Ibl.CRM/Tags/write\`.`,
52073
+ 404: `Tag not found.`
52074
+ }
52075
+ });
52076
+ }
52077
+ /**
52078
+ * Update a tag
52079
+ * Updates only the supplied fields on the Tag (typically `name` or `color`).
52080
+ *
52081
+ * **Required permission:** `Ibl.CRM/Tags/write`.
52082
+ * @returns Tag
52083
+ * @throws ApiError
52084
+ */
52085
+ static tagsPartialUpdate({
52086
+ id,
52087
+ requestBody
52088
+ }) {
52089
+ return request(OpenAPI, {
52090
+ method: 'PATCH',
52091
+ url: '/tags/{id}/',
52092
+ path: {
52093
+ 'id': id
52094
+ },
52095
+ body: requestBody,
52096
+ mediaType: 'application/json',
52097
+ errors: {
52098
+ 400: `Validation error.`,
52099
+ 403: `Missing required permission \`Ibl.CRM/Tags/write\`.`,
52100
+ 404: `Tag not found.`
52101
+ }
52102
+ });
52103
+ }
52104
+ /**
52105
+ * Delete a tag
52106
+ * Deletes the Tag. All attachments to Persons, Organizations, and Deals are removed atomically via cascade.
52107
+ *
52108
+ * **Required permission:** `Ibl.CRM/Tags/delete`.
52109
+ * @returns void
52110
+ * @throws ApiError
52111
+ */
52112
+ static tagsDestroy({
52113
+ id
52114
+ }) {
52115
+ return request(OpenAPI, {
52116
+ method: 'DELETE',
52117
+ url: '/tags/{id}/',
52118
+ path: {
52119
+ 'id': id
52120
+ },
52121
+ errors: {
52122
+ 403: `Missing required permission \`Ibl.CRM/Tags/delete\`.`,
52123
+ 404: `Tag not found.`
52124
+ }
52125
+ });
52126
+ }
52127
+ }
52128
+
51436
52129
  class TransactionsService {
51437
52130
  /**
51438
52131
  * List transaction history
@@ -51504,5 +52197,6 @@ exports.ReportsService = ReportsService;
51504
52197
  exports.ScimService = ScimService;
51505
52198
  exports.SearchService = SearchService;
51506
52199
  exports.SkillsService = SkillsService;
52200
+ exports.TagsService = TagsService;
51507
52201
  exports.TransactionsService = TransactionsService;
51508
52202
  //# sourceMappingURL=index.cjs.js.map