Zoho Projects API Documentation
Text copied
File not found

Project Tags

Disassociate Tags from Entity

Remove associated tags from a module in a project.

POST

/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate

OAuth Scope:

ZohoProjects.tags.UPDATE

Path Parameters

Param Name
Data Type
Description

Query Parameters

Param Name
Data Type
Description

Request Example

Request Example
  • cURL
  • Deluge
  • Node.js
  • Ruby
  • PHP
  • Python
  • C
  • C#
  • C++
  • Clojure
  • Go
  • HTTP
  • Java
  • JS Fetch
  • JSON
  • Kotlin
  • Objective-C
  • OCaml
  • PowerShell
  • R
  • Swift

curl -X POST \
'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate' \
-H 'Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa' \
--form-string 'tag_id=23806000097545166' \
--form-string 'entity_id=1752587000000097299' \
--form-string 'entityType=5'

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate";
params = Map();
params.put("tag_id", "23806000097545166");
params.put("entity_id", "1752587000000097299");
params.put("entityType", "5");
response = invokeUrl
[
    url: url
    type: POST
    parameters: params
    connection: "projects"
];
info response;
const https = require('https');
const url = new URL('https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate');
url.searchParams.append('tag_id', '23806000097545166');
url.searchParams.append('entity_id', '1752587000000097299');
url.searchParams.append('entityType', '5');

const options = {
  hostname: url.hostname,
  path: url.pathname + url.search,
  method: 'POST',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

const req = https.request(options, (res) => {
  let data = '';
  res.on('data', (chunk) => { data += chunk; });
  res.on('end', () => { console.log(JSON.parse(data)); });
});

req.on('error', (err) => { console.error(err); });
req.end();
require 'net/http'
require 'uri'
require 'json'

url = URI("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate")
params = {
  "tag_id" => "23806000097545166",
  "entity_id" => "1752587000000097299",
  "entityType" => "5"
}
url.query = URI.encode_www_form(params)

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"

response = http.request(request)
puts response.read_body
<?php
$params = [
    'tag_id' => '23806000097545166',
    'entity_id' => '1752587000000097299',
    'entityType' => '5',
];
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate" . "?" . http_build_query($params);

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => $url,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  ],
]);

$response = curl_exec($curl);
curl_close($curl);

echo $response;
import requests

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate"

params = {
    "tag_id": "23806000097545166",
    "entity_id": "1752587000000097299",
    "entityType": "5"
}

headers = {
    "Authorization": "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa",
}

response = requests.post(url, headers=headers, params=params)

print(response.json())
#include <stdio.h>
#include <string.h>
#include <curl/curl.h>

int main(void) {
    CURL *curl = curl_easy_init();
    if (curl) {
        char *enc_tag_id = curl_easy_escape(curl, "23806000097545166", 0);
        char *enc_entity_id = curl_easy_escape(curl, "1752587000000097299", 0);
        char *enc_entityType = curl_easy_escape(curl, "5", 0);
        char url[2048];
        snprintf(url, sizeof(url), "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate?tag_id=%s&entity_id=%s&entityType=%s", enc_tag_id, enc_entity_id, enc_entityType);

        struct curl_slist *headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url);
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "POST");

        CURLcode res = curl_easy_perform(curl);
        if (res != CURLE_OK)
            fprintf(stderr, "curl failed: %s\n", curl_easy_strerror(res));

        curl_free(enc_tag_id);
        curl_free(enc_entity_id);
        curl_free(enc_entityType);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
using System.Net.Http;
using System.Text;
using System.Web;

var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

var query = HttpUtility.ParseQueryString(string.Empty);
query["tag_id"] = "23806000097545166";
query["entity_id"] = "1752587000000097299";
query["entityType"] = "5";
var uriBuilder = new UriBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate") { Query = query.ToString() };
var request = new HttpRequestMessage(HttpMethod.Post, uriBuilder.Uri);

var response = await client.SendAsync(request);
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
#include <iostream>
#include <string>
#include <curl/curl.h>

static size_t WriteCallback(void* contents, size_t size, size_t nmemb, std::string* output) {
    output->append((char*)contents, size * nmemb);
    return size * nmemb;
}

int main() {
    CURL* curl = curl_easy_init();
    if (curl) {
        std::string response;
        char* enc_tag_id = curl_easy_escape(curl, "23806000097545166", 0);
        char* enc_entity_id = curl_easy_escape(curl, "1752587000000097299", 0);
        char* enc_entityType = curl_easy_escape(curl, "5", 0);
        std::string url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate";
        url += "?tag_id=" + std::string(enc_tag_id);
        url += "&entity_id=" + std::string(enc_entity_id);
        url += "&entityType=" + std::string(enc_entityType);

        struct curl_slist* headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url.c_str());
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "POST");
        curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, WriteCallback);
        curl_easy_setopt(curl, CURLOPT_WRITEDATA, &response);

        CURLcode res = curl_easy_perform(curl);
        if (res == CURLE_OK)
            std::cout << response << std::endl;
        else
            std::cerr << curl_easy_strerror(res) << std::endl;

        curl_free(enc_tag_id);
        curl_free(enc_entity_id);
        curl_free(enc_entityType);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
(require '[clj-http.client :as client])

(let [enc-tag_id (java.net.URLEncoder/encode "23806000097545166" "UTF-8")
      enc-entity_id (java.net.URLEncoder/encode "1752587000000097299" "UTF-8")
      enc-entityType (java.net.URLEncoder/encode "5" "UTF-8")
      url (str "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate" "?tag_id=" enc-tag_id "&entity_id=" enc-entity_id "&entityType=" enc-entityType)]
(def response
  (client/post url
    {:headers {"Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"}
     :as :json}))

(println (:body response))
package main

import (
    "fmt"
    "io"
    "net/http"
    "net/url"
)

func main() {
    req, _ := http.NewRequest("POST", "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate", nil)
    q := req.URL.Query()
    q.Add("tag_id", "23806000097545166")
    q.Add("entity_id", "1752587000000097299")
    q.Add("entityType", "5")
    req.URL.RawQuery = q.Encode()
    req.Header.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
POST https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate?tag_id=23806000097545166&entity_id=1752587000000097299&entityType=5 HTTP/1.1
Host: https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate?tag_id=23806000097545166&entity_id=1752587000000097299&entityType=5
Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa
HttpClientBuilder httpClientBuilder = HttpClientBuilder.create();

SSLContext sslContext = SSLContext.getDefault();
SSLConnectionSocketFactory sslConnectionSocketFactory = new SSLConnectionSocketFactory(sslContext, NoopHostnameVerifier.INSTANCE);
CloseableHttpClient httpclient = httpClientBuilder.setSSLSocketFactory(sslConnectionSocketFactory).build();

URIBuilder uriBuilder = new URIBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate");
uriBuilder.addParameter("tag_id", "23806000097545166");
uriBuilder.addParameter("entity_id", "1752587000000097299");
uriBuilder.addParameter("entityType", "5");
HttpUriRequest requestObj = new HttpPost(uriBuilder.build());
requestObj.addHeader("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

HttpResponse response = httpclient.execute(requestObj);

HttpEntity responseEntity = response.getEntity();
Object responseObject = EntityUtils.toString(responseEntity);
String responseString = responseObject.toString();
const url = 'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate';

const params = new URLSearchParams({
  'tag_id': '23806000097545166',
  'entity_id': '1752587000000097299',
  'entityType': '5'
});

const options = {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

fetch(url + '?' + params.toString(), options)
  .then(response => response.json())
  .then(data => console.log(data))
  .catch(error => console.error(error));
tag_id = "23806000097545166"
entity_id = "1752587000000097299"
entityType = "5"
import java.net.HttpURLConnection
import java.net.URL
import okhttp3.HttpUrl.Companion.toHttpUrl

fun main() {
    val urlBuilder = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate".toHttpUrl().newBuilder()
    urlBuilder.addQueryParameter("tag_id", "23806000097545166")
    urlBuilder.addQueryParameter("entity_id", "1752587000000097299")
    urlBuilder.addQueryParameter("entityType", "5")
    val url = URL(urlBuilder.build().toString())
    val conn = url.openConnection() as HttpURLConnection
    conn.requestMethod = "POST"
    conn.setRequestProperty("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    val response = conn.inputStream.bufferedReader().readText()
    println(response)
}
NSString *encodedTag_id = [@"23806000097545166" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedEntity_id = [@"1752587000000097299" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedEntityType = [@"5" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *urlString = [NSString stringWithFormat:@"https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate?tag_id=%@&entity_id=%@&entityType=%@", encodedTag_id, encodedEntity_id, encodedEntityType];
NSURL *url = [NSURL URLWithString:urlString];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url];
[request setHTTPMethod:@"POST"];
[request setValue:@"Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa" forHTTPHeaderField:@"Authorization"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *task = [session dataTaskWithRequest:request
    completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
        NSString *result = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
        NSLog(@"%@", result);
}];
[task resume];
open Lwt
open Cohttp_lwt_unix

let () =
  let enc_tag_id = Uri.pct_encode "23806000097545166" in
  let enc_entity_id = Uri.pct_encode "1752587000000097299" in
  let enc_entityType = Uri.pct_encode "5" in
  let uri = Uri.of_string ("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate" ^ "?tag_id=" ^ enc_tag_id ^ "&entity_id=" ^ enc_entity_id ^ "&entityType=" ^ enc_entityType) in
  let headers = Cohttp.Header.init ()
    |> fun h -> Cohttp.Header.add h "Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  in
  Lwt_main.run (
    Client.post ~headers uri >>= fun (_, body) ->
    Cohttp_lwt.Body.to_string body >|= fun s ->
    print_endline s)
$headers = @{
    "Authorization" = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
}

$params = @{
    tag_id = "23806000097545166"
    entity_id = "1752587000000097299"
    entityType = "5"
}
$queryString = ($params.GetEnumerator() | ForEach-Object { "$($_.Key)=$([System.Uri]::EscapeDataString($_.Value))" }) -join "&"
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate" + "?" + $queryString

$response = Invoke-RestMethod -Uri $url -Method POST -Headers $headers

$response | ConvertTo-Json
library(httr)

url <- "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate"

params <- list(
  tag_id = "23806000097545166",
  entity_id = "1752587000000097299",
  entityType = "5"
)

response <- POST(
  url,
  add_headers(Authorization = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"),
  query = params
)

content(response, "text")
import Foundation

var components = URLComponents(string: "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/dissociate")!
components.queryItems = [
    URLQueryItem(name: "tag_id", value: "23806000097545166"),
    URLQueryItem(name: "entity_id", value: "1752587000000097299"),
    URLQueryItem(name: "entityType", value: "5")
]
let url = components.url!
var request = URLRequest(url: url)
request.httpMethod = "POST"
request.setValue("Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa", forHTTPHeaderField: "Authorization")

let semaphore = DispatchSemaphore(value: 0)
let task = URLSession.shared.dataTask(with: request) { data, response, error in
    if let data = data, let result = String(data: data, encoding: .utf8) {
        print(result)
    }
    semaphore.signal()
}
task.resume()
semaphore.wait()

Sample Input

tag_id : "23806000097545166" entity_id : "1752587000000097299" entityType : "5"

Sample Response

204 No Content

Associate Tags to Entity

Associate tags with a module in a project. Note: This API will replace the current associated tags with the new tag IDs if the previous tag IDs are not included in the request.

POST

/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate

OAuth Scope:

ZohoProjects.tags.UPDATE

Path Parameters

Param Name
Data Type
Description

Query Parameters

Param Name
Data Type
Description

Request Example

Request Example
  • cURL
  • Deluge
  • Node.js
  • Ruby
  • PHP
  • Python
  • C
  • C#
  • C++
  • Clojure
  • Go
  • HTTP
  • Java
  • JS Fetch
  • JSON
  • Kotlin
  • Objective-C
  • OCaml
  • PowerShell
  • R
  • Swift

curl -X POST \
'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate' \
-H 'Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa' \
--form-string 'tag_id=23806000097545166' \
--form-string 'entity_id=1752587000000097299' \
--form-string 'entityType=5'

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate";
params = Map();
params.put("tag_id", "23806000097545166");
params.put("entity_id", "1752587000000097299");
params.put("entityType", "5");
response = invokeUrl
[
    url: url
    type: POST
    parameters: params
    connection: "projects"
];
info response;
const https = require('https');
const url = new URL('https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate');
url.searchParams.append('tag_id', '23806000097545166');
url.searchParams.append('entity_id', '1752587000000097299');
url.searchParams.append('entityType', '5');

const options = {
  hostname: url.hostname,
  path: url.pathname + url.search,
  method: 'POST',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

const req = https.request(options, (res) => {
  let data = '';
  res.on('data', (chunk) => { data += chunk; });
  res.on('end', () => { console.log(JSON.parse(data)); });
});

req.on('error', (err) => { console.error(err); });
req.end();
require 'net/http'
require 'uri'
require 'json'

url = URI("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate")
params = {
  "tag_id" => "23806000097545166",
  "entity_id" => "1752587000000097299",
  "entityType" => "5"
}
url.query = URI.encode_www_form(params)

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"

response = http.request(request)
puts response.read_body
<?php
$params = [
    'tag_id' => '23806000097545166',
    'entity_id' => '1752587000000097299',
    'entityType' => '5',
];
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate" . "?" . http_build_query($params);

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => $url,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  ],
]);

$response = curl_exec($curl);
curl_close($curl);

echo $response;
import requests

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate"

params = {
    "tag_id": "23806000097545166",
    "entity_id": "1752587000000097299",
    "entityType": "5"
}

headers = {
    "Authorization": "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa",
}

response = requests.post(url, headers=headers, params=params)

print(response.json())
#include <stdio.h>
#include <string.h>
#include <curl/curl.h>

int main(void) {
    CURL *curl = curl_easy_init();
    if (curl) {
        char *enc_tag_id = curl_easy_escape(curl, "23806000097545166", 0);
        char *enc_entity_id = curl_easy_escape(curl, "1752587000000097299", 0);
        char *enc_entityType = curl_easy_escape(curl, "5", 0);
        char url[2048];
        snprintf(url, sizeof(url), "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate?tag_id=%s&entity_id=%s&entityType=%s", enc_tag_id, enc_entity_id, enc_entityType);

        struct curl_slist *headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url);
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "POST");

        CURLcode res = curl_easy_perform(curl);
        if (res != CURLE_OK)
            fprintf(stderr, "curl failed: %s\n", curl_easy_strerror(res));

        curl_free(enc_tag_id);
        curl_free(enc_entity_id);
        curl_free(enc_entityType);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
using System.Net.Http;
using System.Text;
using System.Web;

var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

var query = HttpUtility.ParseQueryString(string.Empty);
query["tag_id"] = "23806000097545166";
query["entity_id"] = "1752587000000097299";
query["entityType"] = "5";
var uriBuilder = new UriBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate") { Query = query.ToString() };
var request = new HttpRequestMessage(HttpMethod.Post, uriBuilder.Uri);

var response = await client.SendAsync(request);
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
#include <iostream>
#include <string>
#include <curl/curl.h>

static size_t WriteCallback(void* contents, size_t size, size_t nmemb, std::string* output) {
    output->append((char*)contents, size * nmemb);
    return size * nmemb;
}

int main() {
    CURL* curl = curl_easy_init();
    if (curl) {
        std::string response;
        char* enc_tag_id = curl_easy_escape(curl, "23806000097545166", 0);
        char* enc_entity_id = curl_easy_escape(curl, "1752587000000097299", 0);
        char* enc_entityType = curl_easy_escape(curl, "5", 0);
        std::string url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate";
        url += "?tag_id=" + std::string(enc_tag_id);
        url += "&entity_id=" + std::string(enc_entity_id);
        url += "&entityType=" + std::string(enc_entityType);

        struct curl_slist* headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url.c_str());
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "POST");
        curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, WriteCallback);
        curl_easy_setopt(curl, CURLOPT_WRITEDATA, &response);

        CURLcode res = curl_easy_perform(curl);
        if (res == CURLE_OK)
            std::cout << response << std::endl;
        else
            std::cerr << curl_easy_strerror(res) << std::endl;

        curl_free(enc_tag_id);
        curl_free(enc_entity_id);
        curl_free(enc_entityType);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
(require '[clj-http.client :as client])

(let [enc-tag_id (java.net.URLEncoder/encode "23806000097545166" "UTF-8")
      enc-entity_id (java.net.URLEncoder/encode "1752587000000097299" "UTF-8")
      enc-entityType (java.net.URLEncoder/encode "5" "UTF-8")
      url (str "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate" "?tag_id=" enc-tag_id "&entity_id=" enc-entity_id "&entityType=" enc-entityType)]
(def response
  (client/post url
    {:headers {"Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"}
     :as :json}))

(println (:body response))
package main

import (
    "fmt"
    "io"
    "net/http"
    "net/url"
)

func main() {
    req, _ := http.NewRequest("POST", "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate", nil)
    q := req.URL.Query()
    q.Add("tag_id", "23806000097545166")
    q.Add("entity_id", "1752587000000097299")
    q.Add("entityType", "5")
    req.URL.RawQuery = q.Encode()
    req.Header.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
POST https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate?tag_id=23806000097545166&entity_id=1752587000000097299&entityType=5 HTTP/1.1
Host: https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate?tag_id=23806000097545166&entity_id=1752587000000097299&entityType=5
Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa
HttpClientBuilder httpClientBuilder = HttpClientBuilder.create();

SSLContext sslContext = SSLContext.getDefault();
SSLConnectionSocketFactory sslConnectionSocketFactory = new SSLConnectionSocketFactory(sslContext, NoopHostnameVerifier.INSTANCE);
CloseableHttpClient httpclient = httpClientBuilder.setSSLSocketFactory(sslConnectionSocketFactory).build();

URIBuilder uriBuilder = new URIBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate");
uriBuilder.addParameter("tag_id", "23806000097545166");
uriBuilder.addParameter("entity_id", "1752587000000097299");
uriBuilder.addParameter("entityType", "5");
HttpUriRequest requestObj = new HttpPost(uriBuilder.build());
requestObj.addHeader("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

HttpResponse response = httpclient.execute(requestObj);

HttpEntity responseEntity = response.getEntity();
Object responseObject = EntityUtils.toString(responseEntity);
String responseString = responseObject.toString();
const url = 'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate';

const params = new URLSearchParams({
  'tag_id': '23806000097545166',
  'entity_id': '1752587000000097299',
  'entityType': '5'
});

const options = {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

fetch(url + '?' + params.toString(), options)
  .then(response => response.json())
  .then(data => console.log(data))
  .catch(error => console.error(error));
tag_id = "23806000097545166"
entity_id = "1752587000000097299"
entityType = "5"
import java.net.HttpURLConnection
import java.net.URL
import okhttp3.HttpUrl.Companion.toHttpUrl

fun main() {
    val urlBuilder = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate".toHttpUrl().newBuilder()
    urlBuilder.addQueryParameter("tag_id", "23806000097545166")
    urlBuilder.addQueryParameter("entity_id", "1752587000000097299")
    urlBuilder.addQueryParameter("entityType", "5")
    val url = URL(urlBuilder.build().toString())
    val conn = url.openConnection() as HttpURLConnection
    conn.requestMethod = "POST"
    conn.setRequestProperty("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    val response = conn.inputStream.bufferedReader().readText()
    println(response)
}
NSString *encodedTag_id = [@"23806000097545166" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedEntity_id = [@"1752587000000097299" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedEntityType = [@"5" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *urlString = [NSString stringWithFormat:@"https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate?tag_id=%@&entity_id=%@&entityType=%@", encodedTag_id, encodedEntity_id, encodedEntityType];
NSURL *url = [NSURL URLWithString:urlString];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url];
[request setHTTPMethod:@"POST"];
[request setValue:@"Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa" forHTTPHeaderField:@"Authorization"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *task = [session dataTaskWithRequest:request
    completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
        NSString *result = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
        NSLog(@"%@", result);
}];
[task resume];
open Lwt
open Cohttp_lwt_unix

let () =
  let enc_tag_id = Uri.pct_encode "23806000097545166" in
  let enc_entity_id = Uri.pct_encode "1752587000000097299" in
  let enc_entityType = Uri.pct_encode "5" in
  let uri = Uri.of_string ("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate" ^ "?tag_id=" ^ enc_tag_id ^ "&entity_id=" ^ enc_entity_id ^ "&entityType=" ^ enc_entityType) in
  let headers = Cohttp.Header.init ()
    |> fun h -> Cohttp.Header.add h "Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  in
  Lwt_main.run (
    Client.post ~headers uri >>= fun (_, body) ->
    Cohttp_lwt.Body.to_string body >|= fun s ->
    print_endline s)
$headers = @{
    "Authorization" = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
}

$params = @{
    tag_id = "23806000097545166"
    entity_id = "1752587000000097299"
    entityType = "5"
}
$queryString = ($params.GetEnumerator() | ForEach-Object { "$($_.Key)=$([System.Uri]::EscapeDataString($_.Value))" }) -join "&"
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate" + "?" + $queryString

$response = Invoke-RestMethod -Uri $url -Method POST -Headers $headers

$response | ConvertTo-Json
library(httr)

url <- "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate"

params <- list(
  tag_id = "23806000097545166",
  entity_id = "1752587000000097299",
  entityType = "5"
)

response <- POST(
  url,
  add_headers(Authorization = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"),
  query = params
)

content(response, "text")
import Foundation

var components = URLComponents(string: "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags/associate")!
components.queryItems = [
    URLQueryItem(name: "tag_id", value: "23806000097545166"),
    URLQueryItem(name: "entity_id", value: "1752587000000097299"),
    URLQueryItem(name: "entityType", value: "5")
]
let url = components.url!
var request = URLRequest(url: url)
request.httpMethod = "POST"
request.setValue("Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa", forHTTPHeaderField: "Authorization")

let semaphore = DispatchSemaphore(value: 0)
let task = URLSession.shared.dataTask(with: request) { data, response, error in
    if let data = data, let result = String(data: data, encoding: .utf8) {
        print(result)
    }
    semaphore.signal()
}
task.resume()
semaphore.wait()

Sample Input

tag_id : "23806000097545166" entity_id : "1752587000000097299" entityType : "5"

Sample Response

204 No Content

Get Project Tags

Retrieve tags from a project.

GET

/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags

OAuth Scope:

ZohoProjects.tags.READ

Path Parameters

Param Name
Data Type
Description

Query Parameters

Param Name
Data Type
Description

Request Example

Request Example
  • cURL
  • Deluge
  • Node.js
  • Ruby
  • PHP
  • Python
  • C
  • C#
  • C++
  • Clojure
  • Go
  • HTTP
  • Java
  • JS Fetch
  • JSON
  • Kotlin
  • Objective-C
  • OCaml
  • PowerShell
  • R
  • Swift

curl -X GET \
'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags?page=1&per_page=10&filter=%7B%22criteria%22%3A%5B%7B%22field_name%22%3A%22project%22%2C%22criteria_condition%22%3A%22contains%22%2C%22value%22%3A%5B%221752587000000097269%22%5D%7D%5D%2C%22pattern%22%3A%221%22%7D' \
-H 'Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags";
filter_value = {"criteria":[{"field_name":"project","criteria_condition":"contains","value":["1752587000000097269"]}],"pattern":"1"};
params = Map();
params.put("page", "1");
params.put("per_page", "10");
params.put("filter", filter_value);
response = invokeUrl
[
    url: url
    type: GET
    parameters: params
    connection: "projects"
];
info response;
const https = require('https');
const url = new URL('https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags');
url.searchParams.append('page', '1');
url.searchParams.append('per_page', '10');
url.searchParams.append('filter', '{"criteria":[{"field_name":"project","criteria_condition":"contains","value":["1752587000000097269"]}],"pattern":"1"}');

const options = {
  hostname: url.hostname,
  path: url.pathname + url.search,
  method: 'GET',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

const req = https.request(options, (res) => {
  let data = '';
  res.on('data', (chunk) => { data += chunk; });
  res.on('end', () => { console.log(JSON.parse(data)); });
});

req.on('error', (err) => { console.error(err); });
req.end();
require 'net/http'
require 'uri'
require 'json'

url = URI("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags")
params = {
  "page" => "1",
  "per_page" => "10",
  "filter" => "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}"
}
url.query = URI.encode_www_form(params)

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"

response = http.request(request)
puts response.read_body
<?php
$params = [
    'page' => '1',
    'per_page' => '10',
    'filter' => '{"criteria":[{"field_name":"project","criteria_condition":"contains","value":["1752587000000097269"]}],"pattern":"1"}',
];
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags" . "?" . http_build_query($params);

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => $url,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  ],
]);

$response = curl_exec($curl);
curl_close($curl);

echo $response;
import requests

url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags"

params = {
    "page": "1",
    "per_page": "10",
    "filter": "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}"
}

headers = {
    "Authorization": "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa",
}

response = requests.get(url, headers=headers, params=params)

print(response.json())
#include <stdio.h>
#include <string.h>
#include <curl/curl.h>

int main(void) {
    CURL *curl = curl_easy_init();
    if (curl) {
        char *enc_page = curl_easy_escape(curl, "1", 0);
        char *enc_per_page = curl_easy_escape(curl, "10", 0);
        char *enc_filter = curl_easy_escape(curl, "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}", 0);
        char url[2048];
        snprintf(url, sizeof(url), "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags?page=%s&per_page=%s&filter=%s", enc_page, enc_per_page, enc_filter);

        struct curl_slist *headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url);
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "GET");

        CURLcode res = curl_easy_perform(curl);
        if (res != CURLE_OK)
            fprintf(stderr, "curl failed: %s\n", curl_easy_strerror(res));

        curl_free(enc_page);
        curl_free(enc_per_page);
        curl_free(enc_filter);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
using System.Net.Http;
using System.Text;
using System.Web;

var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

var query = HttpUtility.ParseQueryString(string.Empty);
query["page"] = "1";
query["per_page"] = "10";
query["filter"] = "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}";
var uriBuilder = new UriBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags") { Query = query.ToString() };
var request = new HttpRequestMessage(HttpMethod.Get, uriBuilder.Uri);

var response = await client.SendAsync(request);
var body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
#include <iostream>
#include <string>
#include <curl/curl.h>

static size_t WriteCallback(void* contents, size_t size, size_t nmemb, std::string* output) {
    output->append((char*)contents, size * nmemb);
    return size * nmemb;
}

int main() {
    CURL* curl = curl_easy_init();
    if (curl) {
        std::string response;
        char* enc_page = curl_easy_escape(curl, "1", 0);
        char* enc_per_page = curl_easy_escape(curl, "10", 0);
        char* enc_filter = curl_easy_escape(curl, "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}", 0);
        std::string url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags";
        url += "?page=" + std::string(enc_page);
        url += "&per_page=" + std::string(enc_per_page);
        url += "&filter=" + std::string(enc_filter);

        struct curl_slist* headers = NULL;
        headers = curl_slist_append(headers, "Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

        curl_easy_setopt(curl, CURLOPT_URL, url.c_str());
        curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);
        curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, "GET");
        curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, WriteCallback);
        curl_easy_setopt(curl, CURLOPT_WRITEDATA, &response);

        CURLcode res = curl_easy_perform(curl);
        if (res == CURLE_OK)
            std::cout << response << std::endl;
        else
            std::cerr << curl_easy_strerror(res) << std::endl;

        curl_free(enc_page);
        curl_free(enc_per_page);
        curl_free(enc_filter);
        curl_slist_free_all(headers);
        curl_easy_cleanup(curl);
    }
    return 0;
}
(require '[clj-http.client :as client])

(let [enc-page (java.net.URLEncoder/encode "1" "UTF-8")
      enc-per_page (java.net.URLEncoder/encode "10" "UTF-8")
      enc-filter (java.net.URLEncoder/encode "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}" "UTF-8")
      url (str "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags" "?page=" enc-page "&per_page=" enc-per_page "&filter=" enc-filter)]
(def response
  (client/get url
    {:headers {"Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"}
     :as :json}))

(println (:body response))
package main

import (
    "fmt"
    "io"
    "net/http"
    "net/url"
)

func main() {
    req, _ := http.NewRequest("GET", "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags", nil)
    q := req.URL.Query()
    q.Add("page", "1")
    q.Add("per_page", "10")
    q.Add("filter", "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}")
    req.URL.RawQuery = q.Encode()
    req.Header.Add("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
GET https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags?page=1&per_page=10&filter=%7B%22criteria%22%3A%5B%7B%22field_name%22%3A%22project%22%2C%22criteria_condition%22%3A%22contains%22%2C%22value%22%3A%5B%221752587000000097269%22%5D%7D%5D%2C%22pattern%22%3A%221%22%7D HTTP/1.1
Host: https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags?page=1&per_page=10&filter=%7B%22criteria%22%3A%5B%7B%22field_name%22%3A%22project%22%2C%22criteria_condition%22%3A%22contains%22%2C%22value%22%3A%5B%221752587000000097269%22%5D%7D%5D%2C%22pattern%22%3A%221%22%7D
Authorization: Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa
HttpClientBuilder httpClientBuilder = HttpClientBuilder.create();

SSLContext sslContext = SSLContext.getDefault();
SSLConnectionSocketFactory sslConnectionSocketFactory = new SSLConnectionSocketFactory(sslContext, NoopHostnameVerifier.INSTANCE);
CloseableHttpClient httpclient = httpClientBuilder.setSSLSocketFactory(sslConnectionSocketFactory).build();

URIBuilder uriBuilder = new URIBuilder("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags");
uriBuilder.addParameter("page", "1");
uriBuilder.addParameter("per_page", "10");
uriBuilder.addParameter("filter", "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}");
HttpUriRequest requestObj = new HttpGet(uriBuilder.build());
requestObj.addHeader("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa");

HttpResponse response = httpclient.execute(requestObj);

HttpEntity responseEntity = response.getEntity();
Object responseObject = EntityUtils.toString(responseEntity);
String responseString = responseObject.toString();
const url = 'https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags';

const params = new URLSearchParams({
  'page': '1',
  'per_page': '10',
  'filter': '{"criteria":[{"field_name":"project","criteria_condition":"contains","value":["1752587000000097269"]}],"pattern":"1"}'
});

const options = {
  method: 'GET',
  headers: {
    'Authorization': 'Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa'
  }
};

fetch(url + '?' + params.toString(), options)
  .then(response => response.json())
  .then(data => console.log(data))
  .catch(error => console.error(error));
page = "1"
per_page = "10"
filter = {"criteria":[{"field_name":"project","criteria_condition":"contains","value":["1752587000000097269"]}],"pattern":"1"}
import java.net.HttpURLConnection
import java.net.URL
import okhttp3.HttpUrl.Companion.toHttpUrl

fun main() {
    val urlBuilder = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags".toHttpUrl().newBuilder()
    urlBuilder.addQueryParameter("page", "1")
    urlBuilder.addQueryParameter("per_page", "10")
    urlBuilder.addQueryParameter("filter", "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}")
    val url = URL(urlBuilder.build().toString())
    val conn = url.openConnection() as HttpURLConnection
    conn.requestMethod = "GET"
    conn.setRequestProperty("Authorization", "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa")

    val response = conn.inputStream.bufferedReader().readText()
    println(response)
}
NSString *encodedPage = [@"1" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedPer_page = [@"10" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *encodedFilter = [@"{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}" stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]];
NSString *urlString = [NSString stringWithFormat:@"https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags?page=%@&per_page=%@&filter=%@", encodedPage, encodedPer_page, encodedFilter];
NSURL *url = [NSURL URLWithString:urlString];
NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url];
[request setHTTPMethod:@"GET"];
[request setValue:@"Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa" forHTTPHeaderField:@"Authorization"];

NSURLSession *session = [NSURLSession sharedSession];
NSURLSessionDataTask *task = [session dataTaskWithRequest:request
    completionHandler:^(NSData *data, NSURLResponse *response, NSError *error) {
        NSString *result = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
        NSLog(@"%@", result);
}];
[task resume];
open Lwt
open Cohttp_lwt_unix

let () =
  let enc_page = Uri.pct_encode "1" in
  let enc_per_page = Uri.pct_encode "10" in
  let enc_filter = Uri.pct_encode "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}" in
  let uri = Uri.of_string ("https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags" ^ "?page=" ^ enc_page ^ "&per_page=" ^ enc_per_page ^ "&filter=" ^ enc_filter) in
  let headers = Cohttp.Header.init ()
    |> fun h -> Cohttp.Header.add h "Authorization" "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
  in
  Lwt_main.run (
    Client.get ~headers uri >>= fun (_, body) ->
    Cohttp_lwt.Body.to_string body >|= fun s ->
    print_endline s)
$headers = @{
    "Authorization" = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"
}

$params = @{
    page = "1"
    per_page = "10"
    filter = "{`"criteria`":[{`"field_name`":`"project`",`"criteria_condition`":`"contains`",`"value`":[`"1752587000000097269`"]}],`"pattern`":`"1`"}"
}
$queryString = ($params.GetEnumerator() | ForEach-Object { "$($_.Key)=$([System.Uri]::EscapeDataString($_.Value))" }) -join "&"
$url = "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags" + "?" + $queryString

$response = Invoke-RestMethod -Uri $url -Method GET -Headers $headers

$response | ConvertTo-Json
library(httr)

url <- "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags"

params <- list(
  page = "1",
  per_page = "10",
  filter = "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}"
)

response <- GET(
  url,
  add_headers(Authorization = "Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa"),
  query = params
)

content(response, "text")
import Foundation

var components = URLComponents(string: "https://projects.zoho.com/api/v3/portal/[PORTAL_ID]/projects/[PROJECT_ID]/tags")!
components.queryItems = [
    URLQueryItem(name: "page", value: "1"),
    URLQueryItem(name: "per_page", value: "10"),
    URLQueryItem(name: "filter", value: "{\"criteria\":[{\"field_name\":\"project\",\"criteria_condition\":\"contains\",\"value\":[\"1752587000000097269\"]}],\"pattern\":\"1\"}")
]
let url = components.url!
var request = URLRequest(url: url)
request.httpMethod = "GET"
request.setValue("Bearer 1000.03xxxxxxxxxxxxxxxxxa5317.dxxxxxxxxxxxxxxxxxfa", forHTTPHeaderField: "Authorization")

let semaphore = DispatchSemaphore(value: 0)
let task = URLSession.shared.dataTask(with: request) { data, response, error in
    if let data = data, let result = String(data: data, encoding: .utf8) {
        print(result)
    }
    semaphore.signal()
}
task.resume()
semaphore.wait()

Sample Input

page : "1" per_page : "10" filter : { "criteria" : [ { "field_name" : "project", "criteria_condition" : "contains", "value" : [ "1752587000000097269" ] } ], "pattern" : "1" }

Sample Response

200{ "column_size" : { }, "page_info" : { "per_page" : "50", "has_next_page" : "false", "count" : "3", "page" : "1", "sort_by" : [ { "field_names" : [ "usage_count" ], "order_by" : "DESCENDING" } ] }, "tags" : [ { "updated_time" : "2024-09-03T10:45:20.782Z", "created_time" : "2024-09-03T10:45:20.782Z", "usage_count" : 1, "name" : "tag1", "updated_by" : { "zpuid" : "4000000002411", "full_name" : "Hector", "name" : "Hector", "last_name" : "", "id" : "25586378", "first_name" : "Hector", "email" : "hector@zylker.com" }, "id" : "4000000005764", "created_by" : { "zpuid" : "4000000002411", "full_name" : "Hector", "name" : "Hector", "last_name" : "", "id" : "25586378", "first_name" : "Hector", "email" : "hector@zylker.com" }, "color_hexcode" : "#7dcf7b" } ], "filter_fields" : [ { "is_removable" : true, "is_custom_edit" : false, "is_default_field" : false, "table_name" : "ZPTags", "is_default_unassociated" : false, "min_char" : 0, "cfid" : 1, "is_editform_only" : false, "is_pii" : false, "max_char" : 0, "moduleId" : 0, "data_type_integer" : 0, "isLookupField" : false, "is_encrypted" : false, "isCompositeField" : false, "column_name" : "TAG_NAME", "is_editable" : true, "is_resolution" : false, "display_name" : "Title", "is_default" : true, "field_properties" : { }, "sequence" : 0, "field_type_integer" : 0, "isNullable" : false, "isCriteriaCallbackNeeded" : false, "field_type" : "singleline" } ], "column_order" : [ { "is_removable" : true, "is_custom_edit" : false, "is_default_field" : false, "table_name" : "ZPTags", "is_default_unassociated" : false, "min_char" : 0, "cfid" : 2, "is_editform_only" : false, "is_pii" : false, "max_char" : 0, "moduleId" : 0, "data_type_integer" : 0, "isLookupField" : false, "is_encrypted" : false, "isCompositeField" : false, "column_name" : "CREATED_BY", "is_editable" : true, "is_resolution" : false, "display_name" : "Created By", "is_default" : true, "field_properties" : { }, "sequence" : 0, "field_type_integer" : 0, "isNullable" : false, "isCriteriaCallbackNeeded" : false, "field_type" : "userpicklist" } ] }
AI Tools
ChatGPT Open in ChatGPT ↗ Open in ChatGPT to ask questions about this page
Claude Open in Claude ↗ Open in Claude to ask questions about this page
Copy as Markdown Copy this page as markdown to use with AI assistants
View as Markdown ↗ Open this page as markdown in a new tab
Copy OpenAPI Spec Copy the OpenAPI YAML to the clipboard
View as YAML ↗ Open the OpenAPI spec in a new tab
Download YAML Save the OpenAPI spec as a .yaml file