Api TimeKetch

Companies

companiesGet

Listado de todas las companies


/companies

Usage and SDK Samples

curl -X GET\
-H "Accept: application/json"\
"https://timeketch.spira.co/api/companies"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CompaniesApi;

import java.io.File;
import java.util.*;

public class CompaniesApiExample {

    public static void main(String[] args) {
        
        CompaniesApi apiInstance = new CompaniesApi();
        try {
            array[CompaniesResponse] result = apiInstance.companiesGet();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.CompaniesApi;

public class CompaniesApiExample {

    public static void main(String[] args) {
        CompaniesApi apiInstance = new CompaniesApi();
        try {
            array[CompaniesResponse] result = apiInstance.companiesGet();
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesGet");
            e.printStackTrace();
        }
    }
}

CompaniesApi *apiInstance = [[CompaniesApi alloc] init];

// Listado de todas las companies
[apiInstance companiesGetWithCompletionHandler: 
              ^(array[CompaniesResponse] output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.CompaniesApi()
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.companiesGet(callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class companiesGetExample
    {
        public void main()
        {

            var apiInstance = new CompaniesApi();

            try
            {
                // Listado de todas las companies
                array[CompaniesResponse] result = apiInstance.companiesGet();
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CompaniesApi.companiesGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiCompaniesApi();

try {
    $result = $api_instance->companiesGet();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CompaniesApi->companiesGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::CompaniesApi;

my $api_instance = WWW::SwaggerClient::CompaniesApi->new();

eval { 
    my $result = $api_instance->companiesGet();
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CompaniesApi->companiesGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.CompaniesApi()

try: 
    # Listado de todas las companies
    api_response = api_instance.companies_get()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CompaniesApi->companiesGet: %s\n" % e)

Parameters

Responses

Status: 200 - Succesful operation

Status: 500 - Server error


companiesIdGet

Filtrar company por su id

Returns a company by id


/companies/{id}

Usage and SDK Samples

curl -X GET\
-H "Accept: application/json"\
"https://timeketch.spira.co/api/companies/{id}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CompaniesApi;

import java.io.File;
import java.util.*;

public class CompaniesApiExample {

    public static void main(String[] args) {
        
        CompaniesApi apiInstance = new CompaniesApi();
        Long id = 789; // Long | ID de la company
        try {
            CompaniesResponse result = apiInstance.companiesIdGet(id);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesIdGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.CompaniesApi;

public class CompaniesApiExample {

    public static void main(String[] args) {
        CompaniesApi apiInstance = new CompaniesApi();
        Long id = 789; // Long | ID de la company
        try {
            CompaniesResponse result = apiInstance.companiesIdGet(id);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesIdGet");
            e.printStackTrace();
        }
    }
}
Long *id = 789; // ID de la company

CompaniesApi *apiInstance = [[CompaniesApi alloc] init];

// Filtrar company por su id
[apiInstance companiesIdGetWith:id
              completionHandler: ^(CompaniesResponse output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.CompaniesApi()
var id = 789; // {{Long}} ID de la company

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.companiesIdGet(id, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class companiesIdGetExample
    {
        public void main()
        {

            var apiInstance = new CompaniesApi();
            var id = 789;  // Long | ID de la company

            try
            {
                // Filtrar company por su id
                CompaniesResponse result = apiInstance.companiesIdGet(id);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CompaniesApi.companiesIdGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiCompaniesApi();
$id = 789; // Long | ID de la company

try {
    $result = $api_instance->companiesIdGet($id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CompaniesApi->companiesIdGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::CompaniesApi;

my $api_instance = WWW::SwaggerClient::CompaniesApi->new();
my $id = 789; # Long | ID de la company

eval { 
    my $result = $api_instance->companiesIdGet(id => $id);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CompaniesApi->companiesIdGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.CompaniesApi()
id = 789 # Long | ID de la company

try: 
    # Filtrar company por su id
    api_response = api_instance.companies_id_get(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CompaniesApi->companiesIdGet: %s\n" % e)

Parameters

Path parameters
Name Description
id*
Long (int64)
ID de la company
Required

Responses

Status: 200 - Succesful operation

Status: 404 - Data not found


companiesIdPut

Actualizar el registro

Update the data


/companies/{id}

Usage and SDK Samples

curl -X PUT\
-H "Accept: application/json"\
-H "Content-Type: application/json"\
"https://timeketch.spira.co/api/companies/{id}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CompaniesApi;

import java.io.File;
import java.util.*;

public class CompaniesApiExample {

    public static void main(String[] args) {
        
        CompaniesApi apiInstance = new CompaniesApi();
        Long id = 789; // Long | ID de la company
        CompaniesStore body = ; // CompaniesStore | 
        try {
            UpdatedSuccesful result = apiInstance.companiesIdPut(id, body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesIdPut");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.CompaniesApi;

public class CompaniesApiExample {

    public static void main(String[] args) {
        CompaniesApi apiInstance = new CompaniesApi();
        Long id = 789; // Long | ID de la company
        CompaniesStore body = ; // CompaniesStore | 
        try {
            UpdatedSuccesful result = apiInstance.companiesIdPut(id, body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesIdPut");
            e.printStackTrace();
        }
    }
}
Long *id = 789; // ID de la company
CompaniesStore *body = ; //  (optional)

CompaniesApi *apiInstance = [[CompaniesApi alloc] init];

// Actualizar el registro
[apiInstance companiesIdPutWith:id
    body:body
              completionHandler: ^(UpdatedSuccesful output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.CompaniesApi()
var id = 789; // {{Long}} ID de la company
var opts = { 
  'body':  // {{CompaniesStore}} 
};
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.companiesIdPut(id, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class companiesIdPutExample
    {
        public void main()
        {

            var apiInstance = new CompaniesApi();
            var id = 789;  // Long | ID de la company
            var body = new CompaniesStore(); // CompaniesStore |  (optional) 

            try
            {
                // Actualizar el registro
                UpdatedSuccesful result = apiInstance.companiesIdPut(id, body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CompaniesApi.companiesIdPut: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiCompaniesApi();
$id = 789; // Long | ID de la company
$body = ; // CompaniesStore | 

try {
    $result = $api_instance->companiesIdPut($id, $body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CompaniesApi->companiesIdPut: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::CompaniesApi;

my $api_instance = WWW::SwaggerClient::CompaniesApi->new();
my $id = 789; # Long | ID de la company
my $body = WWW::SwaggerClient::Object::CompaniesStore->new(); # CompaniesStore | 

eval { 
    my $result = $api_instance->companiesIdPut(id => $id, body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CompaniesApi->companiesIdPut: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.CompaniesApi()
id = 789 # Long | ID de la company
body =  # CompaniesStore |  (optional)

try: 
    # Actualizar el registro
    api_response = api_instance.companies_id_put(id, body=body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CompaniesApi->companiesIdPut: %s\n" % e)

Parameters

Path parameters
Name Description
id*
Long (int64)
ID de la company
Required
Body parameters
Name Description
body

Responses

Status: 200 - Succesful operation


companiesPost

Guardar una company

Store a company in the app


/companies

Usage and SDK Samples

curl -X POST\
-H "Accept: application/json"\
-H "Content-Type: application/json"\
"https://timeketch.spira.co/api/companies"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.CompaniesApi;

import java.io.File;
import java.util.*;

public class CompaniesApiExample {

    public static void main(String[] args) {
        
        CompaniesApi apiInstance = new CompaniesApi();
        CompaniesStore body = ; // CompaniesStore | 
        try {
            RegisterSuccesful result = apiInstance.companiesPost(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesPost");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.CompaniesApi;

public class CompaniesApiExample {

    public static void main(String[] args) {
        CompaniesApi apiInstance = new CompaniesApi();
        CompaniesStore body = ; // CompaniesStore | 
        try {
            RegisterSuccesful result = apiInstance.companiesPost(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling CompaniesApi#companiesPost");
            e.printStackTrace();
        }
    }
}
CompaniesStore *body = ; //  (optional)

CompaniesApi *apiInstance = [[CompaniesApi alloc] init];

// Guardar una company
[apiInstance companiesPostWith:body
              completionHandler: ^(RegisterSuccesful output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.CompaniesApi()
var opts = { 
  'body':  // {{CompaniesStore}} 
};
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.companiesPost(opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class companiesPostExample
    {
        public void main()
        {

            var apiInstance = new CompaniesApi();
            var body = new CompaniesStore(); // CompaniesStore |  (optional) 

            try
            {
                // Guardar una company
                RegisterSuccesful result = apiInstance.companiesPost(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling CompaniesApi.companiesPost: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiCompaniesApi();
$body = ; // CompaniesStore | 

try {
    $result = $api_instance->companiesPost($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CompaniesApi->companiesPost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::CompaniesApi;

my $api_instance = WWW::SwaggerClient::CompaniesApi->new();
my $body = WWW::SwaggerClient::Object::CompaniesStore->new(); # CompaniesStore | 

eval { 
    my $result = $api_instance->companiesPost(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling CompaniesApi->companiesPost: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.CompaniesApi()
body =  # CompaniesStore |  (optional)

try: 
    # Guardar una company
    api_response = api_instance.companies_post(body=body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling CompaniesApi->companiesPost: %s\n" % e)

Parameters

Body parameters
Name Description
body

Responses

Status: 200 - Successfull operation

Status: 500 - Server error


Login

loginPost

Autenticacion del api

Autenticacion del api para obtener el access token y la informacion del usuario


/login

Usage and SDK Samples

curl -X POST\
-H "Accept: application/json"\
-H "Content-Type: application/json"\
"https://timeketch.spira.co/api/login"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.LoginApi;

import java.io.File;
import java.util.*;

public class LoginApiExample {

    public static void main(String[] args) {
        
        LoginApi apiInstance = new LoginApi();
        Login body = ; // Login | 
        try {
            LoginResponse result = apiInstance.loginPost(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling LoginApi#loginPost");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.LoginApi;

public class LoginApiExample {

    public static void main(String[] args) {
        LoginApi apiInstance = new LoginApi();
        Login body = ; // Login | 
        try {
            LoginResponse result = apiInstance.loginPost(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling LoginApi#loginPost");
            e.printStackTrace();
        }
    }
}
Login *body = ; // 

LoginApi *apiInstance = [[LoginApi alloc] init];

// Autenticacion del api
[apiInstance loginPostWith:body
              completionHandler: ^(LoginResponse output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.LoginApi()
var body = ; // {{Login}} 

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.loginPost(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class loginPostExample
    {
        public void main()
        {

            var apiInstance = new LoginApi();
            var body = new Login(); // Login | 

            try
            {
                // Autenticacion del api
                LoginResponse result = apiInstance.loginPost(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling LoginApi.loginPost: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiLoginApi();
$body = ; // Login | 

try {
    $result = $api_instance->loginPost($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling LoginApi->loginPost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::LoginApi;

my $api_instance = WWW::SwaggerClient::LoginApi->new();
my $body = WWW::SwaggerClient::Object::Login->new(); # Login | 

eval { 
    my $result = $api_instance->loginPost(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling LoginApi->loginPost: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.LoginApi()
body =  # Login | 

try: 
    # Autenticacion del api
    api_response = api_instance.login_post(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling LoginApi->loginPost: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 200 - Successfull operation

Status: 401 - The email or password are incorrect


Schedules

getShiftsPerDayDateGet

Obtener los agendamientos del usuario por día


/get-shifts-per-day/{date}

Usage and SDK Samples

curl -X GET\
-H "Accept: application/json"\
"https://timeketch.spira.co/api/get-shifts-per-day/{date}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.SchedulesApi;

import java.io.File;
import java.util.*;

public class SchedulesApiExample {

    public static void main(String[] args) {
        
        SchedulesApi apiInstance = new SchedulesApi();
        String date = date_example; // String | Fecha del día a consultar
        try {
            array[ShiftsPerDay] result = apiInstance.getShiftsPerDayDateGet(date);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#getShiftsPerDayDateGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.SchedulesApi;

public class SchedulesApiExample {

    public static void main(String[] args) {
        SchedulesApi apiInstance = new SchedulesApi();
        String date = date_example; // String | Fecha del día a consultar
        try {
            array[ShiftsPerDay] result = apiInstance.getShiftsPerDayDateGet(date);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#getShiftsPerDayDateGet");
            e.printStackTrace();
        }
    }
}
String *date = date_example; // Fecha del día a consultar

SchedulesApi *apiInstance = [[SchedulesApi alloc] init];

// Obtener los agendamientos del usuario por día
[apiInstance getShiftsPerDayDateGetWith:date
              completionHandler: ^(array[ShiftsPerDay] output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.SchedulesApi()
var date = date_example; // {{String}} Fecha del día a consultar

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getShiftsPerDayDateGet(date, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getShiftsPerDayDateGetExample
    {
        public void main()
        {

            var apiInstance = new SchedulesApi();
            var date = date_example;  // String | Fecha del día a consultar

            try
            {
                // Obtener los agendamientos del usuario por día
                array[ShiftsPerDay] result = apiInstance.getShiftsPerDayDateGet(date);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling SchedulesApi.getShiftsPerDayDateGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiSchedulesApi();
$date = date_example; // String | Fecha del día a consultar

try {
    $result = $api_instance->getShiftsPerDayDateGet($date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SchedulesApi->getShiftsPerDayDateGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::SchedulesApi;

my $api_instance = WWW::SwaggerClient::SchedulesApi->new();
my $date = date_example; # String | Fecha del día a consultar

eval { 
    my $result = $api_instance->getShiftsPerDayDateGet(date => $date);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SchedulesApi->getShiftsPerDayDateGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.SchedulesApi()
date = date_example # String | Fecha del día a consultar

try: 
    # Obtener los agendamientos del usuario por día
    api_response = api_instance.get_shifts_per_day_date_get(date)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SchedulesApi->getShiftsPerDayDateGet: %s\n" % e)

Parameters

Path parameters
Name Description
date*
String (YYYY-MM-DD)
Fecha del día a consultar
Required

Responses

Status: 200 - Successfull operation

Status: 500 - Error server


shiftsMovementsShiftIdMovementTypeIdPost

Enviar el tipo de movimiento de la agenda


/shifts/movements/{shift_id}/{movement_type_id}

Usage and SDK Samples

curl -X POST\
-H "Accept: application/json"\
-H "Content-Type: application/json"\
"https://timeketch.spira.co/api/shifts/movements/{shift_id}/{movement_type_id}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.SchedulesApi;

import java.io.File;
import java.util.*;

public class SchedulesApiExample {

    public static void main(String[] args) {
        
        SchedulesApi apiInstance = new SchedulesApi();
        Integer shiftId = 56; // Integer | Id de la agenda
        Integer movementTypeId = 56; // Integer | Id del tipo de movimiento
        ShiftMovementType body = ; // ShiftMovementType | 
        try {
            Object result = apiInstance.shiftsMovementsShiftIdMovementTypeIdPost(shiftId, movementTypeId, body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#shiftsMovementsShiftIdMovementTypeIdPost");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.SchedulesApi;

public class SchedulesApiExample {

    public static void main(String[] args) {
        SchedulesApi apiInstance = new SchedulesApi();
        Integer shiftId = 56; // Integer | Id de la agenda
        Integer movementTypeId = 56; // Integer | Id del tipo de movimiento
        ShiftMovementType body = ; // ShiftMovementType | 
        try {
            Object result = apiInstance.shiftsMovementsShiftIdMovementTypeIdPost(shiftId, movementTypeId, body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#shiftsMovementsShiftIdMovementTypeIdPost");
            e.printStackTrace();
        }
    }
}
Integer *shiftId = 56; // Id de la agenda
Integer *movementTypeId = 56; // Id del tipo de movimiento
ShiftMovementType *body = ; //  (optional)

SchedulesApi *apiInstance = [[SchedulesApi alloc] init];

// Enviar el tipo de movimiento de la agenda
[apiInstance shiftsMovementsShiftIdMovementTypeIdPostWith:shiftId
    movementTypeId:movementTypeId
    body:body
              completionHandler: ^(Object output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.SchedulesApi()
var shiftId = 56; // {{Integer}} Id de la agenda
var movementTypeId = 56; // {{Integer}} Id del tipo de movimiento
var opts = { 
  'body':  // {{ShiftMovementType}} 
};
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.shiftsMovementsShiftIdMovementTypeIdPost(shiftIdmovementTypeId, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class shiftsMovementsShiftIdMovementTypeIdPostExample
    {
        public void main()
        {

            var apiInstance = new SchedulesApi();
            var shiftId = 56;  // Integer | Id de la agenda
            var movementTypeId = 56;  // Integer | Id del tipo de movimiento
            var body = new ShiftMovementType(); // ShiftMovementType |  (optional) 

            try
            {
                // Enviar el tipo de movimiento de la agenda
                Object result = apiInstance.shiftsMovementsShiftIdMovementTypeIdPost(shiftId, movementTypeId, body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling SchedulesApi.shiftsMovementsShiftIdMovementTypeIdPost: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiSchedulesApi();
$shiftId = 56; // Integer | Id de la agenda
$movementTypeId = 56; // Integer | Id del tipo de movimiento
$body = ; // ShiftMovementType | 

try {
    $result = $api_instance->shiftsMovementsShiftIdMovementTypeIdPost($shiftId, $movementTypeId, $body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SchedulesApi->shiftsMovementsShiftIdMovementTypeIdPost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::SchedulesApi;

my $api_instance = WWW::SwaggerClient::SchedulesApi->new();
my $shiftId = 56; # Integer | Id de la agenda
my $movementTypeId = 56; # Integer | Id del tipo de movimiento
my $body = WWW::SwaggerClient::Object::ShiftMovementType->new(); # ShiftMovementType | 

eval { 
    my $result = $api_instance->shiftsMovementsShiftIdMovementTypeIdPost(shiftId => $shiftId, movementTypeId => $movementTypeId, body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SchedulesApi->shiftsMovementsShiftIdMovementTypeIdPost: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.SchedulesApi()
shiftId = 56 # Integer | Id de la agenda
movementTypeId = 56 # Integer | Id del tipo de movimiento
body =  # ShiftMovementType |  (optional)

try: 
    # Enviar el tipo de movimiento de la agenda
    api_response = api_instance.shifts_movements_shift_id_movement_type_id_post(shiftId, movementTypeId, body=body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SchedulesApi->shiftsMovementsShiftIdMovementTypeIdPost: %s\n" % e)

Parameters

Path parameters
Name Description
shift_id*
Integer
Id de la agenda
Required
movement_type_id*
Integer
Id del tipo de movimiento
Required
Body parameters
Name Description
body

Responses

Status: 200 - Successfull operation

Status: 500 - Error server


shiftsScheduleDateGet

Obtener los nuevos agendamientos por fecha


/shifts/schedule/{date}

Usage and SDK Samples

curl -X GET\
-H "Accept: application/json"\
"https://timeketch.spira.co/api/shifts/schedule/{date}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.SchedulesApi;

import java.io.File;
import java.util.*;

public class SchedulesApiExample {

    public static void main(String[] args) {
        
        SchedulesApi apiInstance = new SchedulesApi();
        String date = date_example; // String | Fecha del día a consultar
        try {
            array[ShiftsPerDay] result = apiInstance.shiftsScheduleDateGet(date);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#shiftsScheduleDateGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.SchedulesApi;

public class SchedulesApiExample {

    public static void main(String[] args) {
        SchedulesApi apiInstance = new SchedulesApi();
        String date = date_example; // String | Fecha del día a consultar
        try {
            array[ShiftsPerDay] result = apiInstance.shiftsScheduleDateGet(date);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SchedulesApi#shiftsScheduleDateGet");
            e.printStackTrace();
        }
    }
}
String *date = date_example; // Fecha del día a consultar

SchedulesApi *apiInstance = [[SchedulesApi alloc] init];

// Obtener los nuevos agendamientos por fecha
[apiInstance shiftsScheduleDateGetWith:date
              completionHandler: ^(array[ShiftsPerDay] output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var ApiTimeKetch = require('api_time_ketch');

var api = new ApiTimeKetch.SchedulesApi()
var date = date_example; // {{String}} Fecha del día a consultar

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.shiftsScheduleDateGet(date, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class shiftsScheduleDateGetExample
    {
        public void main()
        {

            var apiInstance = new SchedulesApi();
            var date = date_example;  // String | Fecha del día a consultar

            try
            {
                // Obtener los nuevos agendamientos por fecha
                array[ShiftsPerDay] result = apiInstance.shiftsScheduleDateGet(date);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling SchedulesApi.shiftsScheduleDateGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\ApiSchedulesApi();
$date = date_example; // String | Fecha del día a consultar

try {
    $result = $api_instance->shiftsScheduleDateGet($date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling SchedulesApi->shiftsScheduleDateGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::SchedulesApi;

my $api_instance = WWW::SwaggerClient::SchedulesApi->new();
my $date = date_example; # String | Fecha del día a consultar

eval { 
    my $result = $api_instance->shiftsScheduleDateGet(date => $date);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling SchedulesApi->shiftsScheduleDateGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.SchedulesApi()
date = date_example # String | Fecha del día a consultar

try: 
    # Obtener los nuevos agendamientos por fecha
    api_response = api_instance.shifts_schedule_date_get(date)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling SchedulesApi->shiftsScheduleDateGet: %s\n" % e)

Parameters

Path parameters
Name Description
date*
String (YYYY-MM-DD)
Fecha del día a consultar
Required

Responses

Status: 200 - Successfull operation

Status: 500 - Error server